Python For Dummies 1st Edition - PDF Version - Quickly Download The Ebook To Never Miss Important Content
Python For Dummies 1st Edition - PDF Version - Quickly Download The Ebook To Never Miss Important Content
com
https://ebookluna.com/product/python-for-dummies-1st-
edition-pdf-version/
OR CLICK HERE
DOWLOAD EBOOK
https://ebookluna.com/product/ebook-pdf-cloud-computing-for-dummies-
by-judith-hurwitz/
ebookluna.com
https://ebookluna.com/download/python-distilled-ebook-pdf/
ebookluna.com
https://ebookluna.com/product/ebook-pdf-building-python-programs-1st-
edition/
ebookluna.com
https://ebookluna.com/product/adobe-photoshop-cc-for-
photographers-2018-1st-edition-pdf-version/
ebookluna.com
R and Python for Oceanographers: A Practical Guide with
Applications 1st Edition- eBook PDF
https://ebookluna.com/download/r-and-python-for-oceanographers-a-
practical-guide-with-applications-ebook-pdf/
ebookluna.com
https://ebookluna.com/download/problem-solving-and-python-programming-
ebook-pdf/
ebookluna.com
https://ebookluna.com/download/programming-and-problem-solving-with-
python-ebook-pdf/
ebookluna.com
https://ebookluna.com/product/ebook-pdf-django-for-professionals-
production-websites-with-python-django/
ebookluna.com
https://ebookluna.com/product/ebook-pdf-python-for-everyone-2nd-
edition-by-cay-s-horstmann/
ebookluna.com
Chapter 1 describes the history of Python and all the exciting things it's being used for
today. You find out why computers are both the fastest and dumbest things around. Best
of all, you discover why it's called Python anyway.
Chapter 2 lets you talk to Python via its interactive mode and IDLE environment. You
write a few basic programs and find out how to get Python to carry out commands for
you, how to get Python to tell you things, and how to import tools that let you do even
more.
Chapter 3 introduces you to Python's data types and code blocks, the chunks you use to
build programs.
Chapter 4 shows you a working program. You see how all the chunks of a Python
program talk to each other, and you find out something about the design philosophies
behind Python programs.
Chapter 5 lets you try on a programmer's hat to understand how programmers work and
why they make the design decisions they do. (Unfortunately, it doesn't explain the
relevance of caffeinated sodas to this process—you'll have to figure that out for yourself.)
There's also a very useful section on strategies for debugging programs, which is a huge
part of every programmer's job.
Python is ideal for projects that require quick development. It supports multiple
programming philosophies, so it's good for programs that require flexibility. The many
packages and modules already written for Python provide versatility and save you time.
7
Guido van Rossum created Python and is affectionately bestowed with the title
"Benevolent Dictator For Life" by the Python community. In the late 1980s, Guido liked
features of several programming languages, but none of them had all the features he
wanted. Specifically, he wanted a language that had the following features:
8
your application work. Guido began writing Python during his Christmas vacation
in 1989, and over the next year, he added to the program based on feedback from
colleagues. He released it to the public in February 1991 by posting to the Usenet
system of newsgroups. In Guido's words: "The rest is in the Misc/HISTORY file."
Fast development
High-level features make Python a wise alternative for prototyping and fast development
of complex applications:
Programming styles
9
o Perl: A procedural language used for text manipulation, system
administration, Web development, and network programming
o Tcl: Used for rapid prototyping, scripting, GUIs, and testing
o Scheme: A functional programming language (a language that focuses on
performing actions and calculations by using functions.
For more about functions, see Chapter 11, and for an intro to functional
programming, see Chapter 16.)
Versatility
Python modules (collections of features for performing tasks) let Python work with
Python comes with dozens of built-in modules. New modules can be written in either
Python or C/C++.
The main portal to Python and the Python community is http://www.python.org. This
portal contains a page that lists some companies that use Python, including
Other commercial uses include financial applications, educational software, games, and
business software.
Convenience
Most programming languages offer convenience features, but none boast the combination
of convenience and power that Python offers:
10
• Python can be embedded in other applications and used for creating macros.
For example, Python is embedded in Paint Shop Pro 8 and later versions as a
scripting language.
• Python is free for anyone to use and distribute (commercially or
noncommercially), so any individual or company can use it without paying
license fees.
• Python has powerful text manipulation and search features for applications
that process a lot of text information.
• You can build large applications with Python, even though it doesn't check
programs before they run. In technical terms, Python doesn't have compile-time
checking. Python supports large programs by connecting multiple modules
together and bundling them into packages. Each module can be built and tested
separately.
• Python includes support for testing and error-checking both of individual
modules and of whole programs.
Python by itself isn't best for applications that need to interface closely with the
computer's hardware because
• Python is a high-level language that uses many layers to communicate with the
computer's hardware and operating system.
REMEMBER Python might not be the best choice for building the following types of
applications and systems:
• Graphics-intensive applications, such as action games
But some games use Python because specialized modules can be written to
interface with hardware. The pygame module is one such package. (Modern
computers are extremely fast, which means it's more important to be able to write
clean code quickly than to get maximum speed out of the software, except for the
most graphics-intensive games.)
Python has attracted many users who collectively make up a community that
• Promotes Python
• Discusses and implements improvements to the language
11
• Supports newcomers
• Encourages standards and conventions that improve Python's usability and
readability
• Values simplicity and fun (after all, Python was named after Monty Python, the
British comedy troupe)
Unpythonic code is roughly translated from other languages instead of following Python's
philosophy.
Pythonistas are knowledgeable users of Python (especially users who promote the
language).
Cooking Up Programs
Writing programs is a little bit like working with recipes. For example, you can
In Python, you can build a program from scratch, writing all your own code and
using only Python's basic built-in functions.
• Use the product of one recipe in another recipe (for example, a recipe for
turkey stuffing uses bread as an ingredient).
After you write program that performs a basic task, you can insert it into other
programs the same way you add any ingredient to a recipe.
Python comes with many modules, which are sets of programs other people have
written that you can plug into your program, just like you can buy bread at the
store without baking it yourself.
Python's even better than bread because most Python modules are free!
12
When you write a program, you are telling the computer to do something. Python For
Dummies gives you step-by-step instructions that help you understand how to write the
way a computer "thinks."
REMEMBER Unlike you, computers are pretty stupid. They can do only a few things.
All the actions that humans make them do are the result of the computer's
doing those few things over and over, in different combinations, very
quickly.
Imagine that you're a baker, and you have taken on an apprentice baker who is as stupid
as a computer. If you want to show your baker how to make bread from scratch, you need
to start with very basic steps. You've already started by putting warm water and sugar in a
small bowl. Then you and the apprentice have this conversation:
By now you might doubt the wisdom of hiring an apprentice baker who needs to be told
things that seem completely obvious to you. But if you persevere, you'll come out ahead.
If this apprentice is like a computer, then after finally figuring out how to bake bread in
your kitchen, your new baker will be able to prepare 100 loaves a minute!
Combining ingredients
When your apprentice baker knows all the procedures involved in baking bread, such as
finding the ingredients on the shelves, finding the pots and pans, mixing ingredients, and
operating the oven, you can assign other tasks that use those same procedures. Baking
bread involves combining ingredients in a bowl, so if you need to combine ingredients
for another recipe, the apprentice already knows how to do that. So when you want to
explain how to make cookies, you can now say "combine sugar, flour, and butter in a
bowl" without explaining where to find the bowls or the sugar.
REMEMBER In Python, after you've written a program to do something, you can import
it into another program. So the more you work with Python, the faster
you'll be able to write programs.
13
Chapter 2: Getting your Hands on the
Keyboard—Using Help, Interactive
Mode, and IDLE
Overview
Even if you haven't used Python or another programming language before, it's easy to get
up and running with Python. You don't even have to know how to write a complete
program because you can run Python in interactive mode. In interactive mode, you can
tell Python what to do one instruction at a time, or you can write small portions of code to
see how Python handles them. In this way you can learn by doing, trying things out at
your own pace.
If you've worked with other programming languages, you're probably eager to get into
the workings of Python and see how it compares. This chapter introduces you to some of
the tools you'll use as you develop Python programs, as well as some of Python's basic
syntax.
Ready for a full-on development experience? Or just curious what a debugger is? Then
go on to the "IDLE Musings" section about Python's very own development environment,
IDLE (Integrated DeveLopment Environment). This comprehensive set of tools supports
you when you are writing, testing, and finding or fixing mistakes in programs.
Tip In most of this book, you read and experiment on your own; it's structured so that
you can pick up information without reading sequentially. However, if you're new to
programming, you might find it useful to read all of this chapter and try some
examples before going on to the rest of the book. In the following sections, you get a
good "hands-on" foundation with Python's interpreter, which will make you more
comfortable when you move on to writing your own programs.
Tip If you want to get an overview of Python's features, jump ahead to Chapter 3. We'll
be waiting for you here when you want to find out more about interactive mode or
the IDLE editor/debugger.
14
• Interactive mode: In interactive mode, you type instructions to Python one line
at a time—much the same way that an operating system (shell) accepts
instructions from a command line. You can also write short multiline programs or
import code from text files or from Python's builtin modules. Interactive mode
includes extensive help, too. With interactive mode, you can explore Python's
abilities.
• IDLE: The IDLE development environment includes Python's interactive mode
and more—tools for writing and running programs and for keeping track of
names.
Warning You can't save what you type in interactive mode. If you want to keep a copy of
what you wrote, save your code and results in a file on your computer.
You can use interactive mode as a calculator. You can manipulate text and make
assignments in interactive mode. Finally, you can import modules, functions, or parts of a
longer program and test them. These features can help you
When Python opens, you see the text shown in Figure 2-1.
15
Visit https://testbankfan.com
now to explore a rich
collection of testbank or
solution manual and enjoy
exciting offers!
When Python's interactive mode starts up, it tells you what version is running, the date
the version was released, and a few hints about what to do next. Then it displays the
Python prompt: >>>
"Hello, World" programs are a computer programming tradition. According to the free
Internet encyclopedia Wikipedia (http://www.wikipedia.org), the first instance of a
computer program that printed "Hello, World" occurred in 1973, in a book called A
Tutorial Introduction to the Language B, by Brian Kernighan. Since then, a "Hello,
World!" program has been written for almost every computer language. Wikipedia lists
more than 170 "Hello, World!" programs written in languages from 4GL and ActionScript
to UNIX shell and XUL.
One reason that "Hello, World" programs are popular is that a program that prints a single
statement is usually the shortest working program in a language.
The basic method for working with interactive mode is simply this:
When you press Return, Python interprets your input and responds if what you typed
calls for a response or if the interpreter doesn't understand what you typed.
In the following example, the statement tells Python to print a string. Because the
statement doesn't specify where to print the string, Python prints it to the screen (the
default behavior in interactive mode).
16
This statement is a whole Python program! Pretty simple, eh? When you use interactive
mode, Python processes each line of code you type as soon as you press Return (unless it
sees that you are writing a multiline chunk of code), and the results appear underneath.
In interactive mode, there are two ways to see information about an object:
• With some data types (integers and lists, for example), the two methods of seeing
the value give the same result—as in this example, in which the name stores a list:
• >>> x = [3,2]
• >>> x
• [3, 2]
• >>> print x
• [3, 2]
• With strings, the result of typing print name and pressing Return is slightly
different from the result you get by typing name and pressing Return. When you
just type name and press Return, the value is surrounded by quotation marks, but
when you type print name and press Return, there are no quotation marks. (To
find out why, see the sidebar, "Representing data".)
This example shows the difference between using just the name and using the
print statement with the name:
>>> x = "mystring"
>>> x
"mystring"
>>> print x
mystring
• When the name refers to a code block (for example, a function, module, or class
instance), looking at the name shows you information such as the kind of data, the
name, and the storage location.
This example creates a class called Message and displays information about the
class:
17
__main__.Message
Representing data
Why do you sometimes see different results when you type name and when you type
print name? Just typing name and pressing Return is a shortcut for using the function
repr() to display the result, whereas the print command uses the function str() to
display the result.
In technical terms, when you type an object name, literal, expression, or statement and
press Return, Python evaluates the object. That is, Python runs the code and
returns/displays the result.
According to Python's built-in documentation, the function str() returns a "nice" string
representation of an object. The function repr() returns the "canonical" string
representation of the object. Here's the difference between a "nice" and a "canonical"
representation of a floating point number:
The canonical representation usually tries to be a chunk of text that, when pasted into the
interpreter, re-creates the object. This example shows how:
(Note that some objects, such as files, can't be re-created by repr(). You can still use the
output of repr() as debugging info when working with such objects.)
Here's an example of what str() and repr() return when you give them a class as an
argument:
18
Seeing the result of the last expression
When you type an expression by itself in interactive mode, or when Python returns an
expression as a result of something you typed, Python also stores the value of the
expression in a special name: _ (an underscore character). This name is available only in
interactive mode. To see the value stored, type _.
You can use Python's interactive mode to see a few of the interesting tricks Python can do
with string and list data. (We cover strings and lists in Chapters 6 and 8.)
When you want to print several strings, or a string and the value of a name, you can use a
comma to stand for a single space in the printed output. The following example shows the
comma in action:
>>> x = "supercalifragilisticexpialidocious"
>>> len(x)
34
REMEMBER len() works with other sequence data types, too—for example, if you
19
give it a list as an argument, it returns the number of items in the list.
The method split() breaks a string into separate words and returns a list
of the words, like this:
The Python interpreter can be used like a calculator. If you just want to do simple
calculations, you can type numbers and operators and press Return to see the result, as in
the following example:
>>> (1 + 3) * (2 + 2)
16
>>> 1 + 3 * 2 + 2
9
Warning Don't use an equals sign (=) when doing calculations like these. In Python, an
equals sign gives a name to a value. If you use = to try to get the result of a
calculation, Python gives you an error message:
>>> 1 + 3 * 2 + 2 =
File "<stdin>", line 1
1 + 3 * 2 + 2 =
^
SyntaxError: invalid syntax
You can also use names to do math in the Python interpreter. This is easier when doing
calculations with several steps, like the following:
>>> x = 1 + 3
>>> y = 2 + 2
>>> x * y
16
Warning If you type all whole numbers (integers) when you're doing arithmetic, Python
returns the result in integers. If you want precise results in calculations
involving division, be sure that at least one of the numbers in a calculation is a
decimal number, or type the statement from __future__ import division
before doing your calculations. Doing the latter imports the true division feature
from a special module called __future__, which contains improvements that
will be automatically activated in later versions of Python. To find out more
20
Random documents with unrelated
content Scribd suggests to you:
An agricultural association, or farmers’ club, has been formed under
the patronage of the Duke of Sutherland, of which the other
proprietors in the county, and the larger tenantry, are members,
which is in a very active and flourishing state. They have recently
invited Professor Johnston to visit Sutherland and give lectures on
agricultural chemistry.
The total population of the Sutherland estate is twenty-one thousand
seven hundred and eighty-four. To have the charge and care of so
large an estate, of course, must require very systematic
arrangements; but a talent for system seems to be rather the forte
of the English.
The estate is first divided into three districts, and each district is
under the superintendence of a factor, who communicates with the
duke through a general agent. Besides this, when the duke is on the
estate, which is during a portion of every year, he receives on
Monday whoever of his tenants wishes to see him. Their complaints
or wishes are presented in writing; he takes them into consideration,
and gives written replies.
Besides the three factors there is a ground officer, or sub-factor, in
every parish, and an agriculturist in the Dunrobin district, who gives
particular attention to instructing the people in the best methods of
farming. The factors, the ground officers, and the agriculturists, all
work to one common end. They teach the advantages of draining; of
ploughing deep, and forming their ridges in straight lines; of
constructing tanks for saving liquid manure. The young farmers also
pick up a great deal of knowledge when working as ploughmen or
labourers on the more immediate grounds of the estate.
The head agent, Mr. Loch, has been kind enough to put into my
hands a general report of the condition of the estate, which he drew
up for the inspection of the duke, May 12, 1853, and in which he
goes minutely over the condition of every part of the estate.
One anecdote of the former Duke of Sutherland will show the spirit
which has influenced the family in their management of the estate.
In 1817, when there was much suffering on account of bad seasons,
the Duke of Sutherland sent down his chief agent to look into the
condition of the people, who desired the ministers of the parishes to
send in their lists of poor. To his surprise it was found that there
were located on the estate a number of people who had settled
there without leave. They amounted to four hundred and eight
families, or two thousand persons; and though they had no legal
title to remain where they were, no hesitation was shown in
supplying them with food in the same manner with those who were
tenants, on the sole condition that on the first opportunity they
should take cottages on the sea-shore, and become industrious
people. It was the constant object of the duke to keep the rents of
his poorer tenants at a nominal amount.
What led me more particularly to inquire into these facts was, that I
received by mail, while in London, an account containing some of
these stories, which had been industriously circulated in America.
There were dreadful accounts of cruelties practised in the process of
inducing the tenants to change their places of residence. The
following is a specimen of these stories:—
“I was present at the pulling down and burning of the house of
William Chisholm, Badinloskin, in which was lying his wife’s mother,
an old, bed-ridden woman of near one hundred years of age, none
of the family being present. I informed the persons about to set fire
to the house of this circumstance, and prevailed on them to wait till
Mr. Sellar came. On his arrival I told him of the poor old woman,
being a condition unfit for removal. He replied, ‘The old witch! she
has lived too long; let her burn.’ Fire was immediately set to the
house, and the blankets in which she was carried were in flames
before she could be got out. She was placed in a little shed, and it
was with great difficulty they were prevented from firing that also.
The old woman’s daughter arrived while the house was on fire, and
assisted the neighbours in removing her mother out of the flames
and smoke, presenting a picture of horror which I shall never forget
but cannot attempt to describe. She died within five days.”
With regard to this story, Mr. Loch, the agent, says: “I must notice
the only thing like a fact stated in the newspaper extract which you
sent to me, wherein Mr. Sellar is accused of acts of cruelty towards
some of the people. This Mr. Sellar tested, by bringing an action
against the then Sheriff-substitute of the county. He obtained a
verdict for heavy damages. The Sheriff, by whom the slander was
propagated, left the county. Both are since dead.”
Having, through Lord Shaftesbury’s kindness, received the benefit of
Mr. Loch’s corrections to this statement, I am permitted to make a
little further extract from his reply. He says:—
“In addition to what I was able to say in my former paper, I can now
state that the Duke of Sutherland has received from one of the most
determined opposers of the measures, who travelled to the north of
Scotland as editor of a newspaper, a letter regretting all he had
written on the subject, being convinced that he was entirely
misinformed. As you take so much interest in the subject, I will
conclude by saying that nothing could exceed the prosperity of the
county during the past year; their stock, sheep, and other things
sold at high prices; their crops of grain and turnips were never so
good, and the potatoes were free from all disease: rents have been
paid better than was ever known. * * * As an instance of the
improved habits of the farmers, no house is now built for them that
they do not require a hot bath and water-closets.”
From this long epitome you can gather the following results. First, if
the system were a bad one, the Duchess of Sutherland had nothing
to do with it, since it was first introduced in 1806, the same year her
grace was born; and the accusation against Mr. Sellar, dates in 1811,
when her grace was five or six years old. The Sutherland
arrangements were completed in 1819, and her grace was not
married to the duke till 1823, so that, had the arrangement been the
worst in the world, it is nothing to the purpose so far as she is
concerned.
As to whether the arrangement is a bad one, the facts which have
been stated speak for themselves. To my view it is an almost
sublime instance of the benevolent employment of superior wealth
and power in shortening the struggles of advancing civilization, and
elevating in a few years a whole community to a point of education
and material prosperity, which, unassisted, they might never have
obtained.
But you shall find the Duke’s money is expended for most
astonishing purposes; not a little of it goes to hire hypocrites, and
renowned literary flatterers, to vindicate the mal-administration of
those to whom he entrusted the management of his affairs, and
make his Grace (who is by nature a simple-minded man) believe his
servants are innocent of all the charges brought against them, and
doing justice to himself and to his people, when they are doing the
greatest injustice to both; so that instead of calling his servants to
account at any time, and enquiring into the broad charges brought
against them—as every wise landlord should do—it seems the
greater the enormities of foul deeds they commit, and the louder
their accusations may sound through the land, the farther they are
received into his favour. The fact is, that James Loch was Duke of
Sutherland, and not the “tall, slender man with rather a thin face,
light brown hair, and mild blue eyes,” who armed you up the
extraordinary elegant staircase in Stafford House.
The Duchess of Sutherland pays a visit every year to Dunrobin
Castle, and has seen and heard so many supplicating appeals
presented to her husband by the poor fishermen of Golspie,
soliciting liberty to take mussels from the Little Ferry Sands to bait
their nets—a liberty of which they were deprived by his factors,
though paying yearly rent for it; yet returned by his Grace with the
brief deliverance, that he could do nothing for them. Can I believe
that this is the same personage who can set out from Dunrobin
Castle, her own Highland seat, and after travelling from it, then can
ride in one direction over thirty miles, in another direction forty-four
miles, in another, by taking the necessary circuitous route, sixty
miles, and that over fertile glens, valleys, and straths, bursting with
fatness, which gave birth to, and where were reared for ages,
thousands of the bravest, the most moral, virtuous, and religious
men that Europe could boast of; ready to a man, at a moment’s
warning from their chiefs, to rise in defence of their king, queen, and
country; animated with patriotism and love to their chief, and
irresistible in the battle contest for victory? But these valiant men
had then a country, a home, and a chief worth the fighting for. But I
can tell her that she can now ride over these extensive tracts in the
interior of the county without seeing the image of God upon a man
travelling these roads, with the exception of a wandering Highland
shepherd, wrapped up in a grey plaid to the eyes, with a collie dog
behind him as a drill sergeant to train his ewes and to marshal his
tups. There may happen to travel over the dreary tract a geologist, a
tourist, or a lonely carrier, but these are as rare as a pelican in the
wilderness, or a camel’s convoy caravan in the deserts of Arabia. Add
to this a few English sportsmen, with their stag hounds, pointer
dogs, and servants, and put themselves and their bravery together,
and one company of French soldiers would put ten thousand of them
to a disorderly flight, to save their own carcases, leaving their ewes
and tups to feed the invaders!
The question may arise, where those people, who inhabited this
country at one period, have gone? In America and Australia the most
of them will be found. The Sutherland family and the nation had no
need of their services; hence they did not regard their patriotism or
loyalty, and disregarded their past services. Sheep, bullocks, deer,
and game, became more valuable than men. Yet a remnant, or in
other words a skeleton, of them is to be found along the sea shore,
huddled together in motley groups upon barren moors, among cliffs
and precipices, in the most impoverished, degraded, subjugated,
slavish, spiritless, condition that human beings could exist in. If this
is really the lady who has “Glory to God in the highest, peace on
earth, and good will to men,” in view, and who is so religiously
denouncing the American statute which “denies the slave the
sanctity of marriage, with all its joys, rights, and obligations—which
separates, at the will of the master, the wife from the husband, the
children from the parents,” I would advise her in God’s name to take
a tour round the sea-skirts of Sutherland, her own estate, beginning
at Brora, then to Helmsdale, Portskerra, Strathy, Farr, Tongue,
Durness, Eddrachillis, and Assynt, and learn the subjugated,
degraded, impoverished, uneducated condition of the spiritless
people of that sea-beaten coast, about two hundred miles in length,
and let her with similar zeal remonstrate with her husband, that their
condition is bettered; for the cure for all their misery and want is
lying unmolested in the fertile valleys above, and all under his
control; and to advise his Grace, her husband, to be no longer
guided by his Ahitophel, Mr. Loch, but to discontinue his
depopulating schemes, which have separated many a wife from her
husband, never to meet—which caused many a premature death,
and that separated many sons and daughters, never to see each
other; and by all means to withdraw that mandate of Mr. Loch,
which forbids marriage on the Sutherland estate, under pains and
penalties of being banished from the county; for it has already
augmented illegitimate connections and issues fifty per cent above
what such were a few years ago—before this unnatural, ungodly law
was put in force.
Let us see what the character of these ill-used people was! General
Stewart of Garth, in his “Sketches of the Highlands” says: In the
words of a general officer by whom the 93rd Sutherlanders were
once reviewed, “They exhibit a perfect pattern of military discipline
and moral rectitude. In the case of such men disgraceful punishment
would be as unnecessary as it would be pernicious.” “Indeed,” says
the General, “so remote was the idea of such a measure in regard to
them, that when punishments were to be inflicted on others, and the
troops in garrison assembled to witness their execution, the
presence of the Sutherland Highlanders was dispensed with, the
effects of terror as a check to crime being in their case uncalled for,
as examples of that nature were not necessary for such honourable
soldiers. When the Sutherland Highlanders were stationed at the
Cape of Good Hope anxious to enjoy the advantages of religious
instruction agreeably to the tenets of their national church, and
there being no religious service in the garrison except the customary
one of reading prayers to the soldiers on parade, the Sutherland
men formed themselves into a congregation, appointed elders of
their own number, engaged and paid a stipend (collected among
themselves) to a clergyman of the Church of Scotland, and had
divine service performed agreeably to the ritual of the Established
Church every Sabbath, and prayer meetings through the week.” This
reverend gentleman, Mr. Thom, in a letter which appeared in the
Christian Herald of October, 1814, writes thus: “When the 93rd
Highlanders left Cape Town last month, there were among them 156
members of the church, including three elders and three deacons, all
of whom, so far as men can know the heart from the life, were pious
men. The regiment was certainly a pattern of morality, and good
behaviour to all other corps. They read their Bibles and observed the
Sabbath. They saved their money to do good. 7000 rix dollars, a
sum equal to £1200, the non-commissioned officers and privates
saved for books, societies, and for the spread of the Gospel, a sum
unparalleled in any other corps in the world, given in the short space
of eighteen months. Their example had a general good effect on
both the colonists and the heathen. If ever apostolic days were
revived in modern times on earth, I certainly believe some of those
to have been granted to us in Africa.” Another letter of a similar kind,
addressed to the Committee of the Edinburgh Gaelic School Society
(fourth annual report), says: “The 93rd Highlanders arrived in
England, when they immediately received orders to proceed to North
America; but before they re-embarked the sum collected for your
society was made up and remitted to your treasurer, amounting to
seventy-eight pounds, sterling.” “In addition to this,” says the noble-
minded, immortal General, “such of them as had parents and friends
in Sutherland did not forget their destitute condition, occasioned by
the operation of the fire and faggot, mis-improved state of the
county.” During the short period the regiment was quartered at
Plymouth, upwards of £500 was lodged in one banking-house, to be
remitted to Sutherland, exclusive of many sums sent through the
Post Office and by officers; some of the sums exceeding £20 from an
individual soldier. Men like these do credit to the peasantry of a
country. “It must appear strange, and somewhat inconsistent,”
continues the General, “when the same men who are so loud in their
profession of an eager desire to promote and preserve the religious
and moral virtues of the people, should so frequently take the lead
in removing them from where they imbibed principles which have
attracted the notice of Europe and of measures which lead to a
deterioration, placing families on patches of potato ground as in
Ireland, a system pregnant with degradation, poverty, and
disaffection.” It is only when parents and heads of families in the
Highlands are moral, happy, and contented, that they can instil
sound principles into their children, who in their intercourse with the
world may become what the men of Sutherland have already been,
“an honourable example, worthy the imitation of all.”
I cannot help being grieved at my unavoidable abbreviation of these
heart-stirring and heart-warming extracts, which should ornament
every mantel-piece and library in the Highlands of Scotland; but I
could refer to other authors of similar weight; among the last
(though not the least), Mr. Hugh Millar of the Witness, in his
“Sutherland as it was and is: or, How a country can be ruined;” a
work which should silence and put to shame every vile, malignant
calumniator of Highland religion and moral virtue in bygone years,
who in their sophistical profession of a desire to promote the
temporal and spiritual welfare of the people, had their own sordid
cupidity and aggrandisement in view in all their unworthy
lucubrations.
At the commencement of the Russian war a correspondent wrote as
follows: “Your predictions are making their appearance at last, great
demands are here for men to go to Russia, but they are not to be
found. It seems that the Secretary of War has corresponded with all
our Highland proprietors, to raise as many men as they could for the
Crimean war, and ordered so many officers of rank to the Highlands
to assist the proprietors in doing so—but it has been a complete
failure as yet. The nobles advertised, by placards, meetings of the
people; these proclamations were attended to, but when they came
to understand what they were about, in most cases the recruiting
proprietors and staff were saluted with the ominous cry of ‘Maa!
maa! boo! boo!’ imitating sheep and bullocks, and, ‘Send your deer,
your roes, your rams, dogs, shepherds, and gamekeepers to fight
the Russians, they have never done us any harm.’ The success of his
Grace the Duke of Sutherland was deplorable; I believe you would
have pitied the poor old man had you seen him.
“In my last letter I told you that his head commissioner, Mr. Loch,
and military officer, was in Sutherland for the last six weeks, and
failed in getting one man to enlist; on getting these doleful tidings,
the Duke himself left London for Sutherland, arriving at Dunrobin
about ten days ago, and after presenting himself upon the streets of
Golspie and Brora, he called a meeting of the male inhabitants of the
parishes of Clyne, Rogart, and Golspie; the meeting was well
attended; upwards of 400 were punctual at the hour; his Grace in
his carriage, with his military staff and factors appeared shortly
after; the people gave them a hearty cheer; his Grace took the chair.
Three or four clerks took their seats at the table, and loosened down
bulky packages of bank notes, and spread out platefuls of glittering
gold. The Duke addressed the people very seriously, and entered
upon the necessity of going to war with Russia, and the danger of
allowing the Czar to have more power than what he holds already;
of his cruel, despotic reign in Russia, etc.; likewise praising the
Queen and her government, rulers and nobles of Great Britain, who
stood so much in need of men to put and keep down the tyrant of
Russia, and foil him in his wicked schemes to take possession of
Turkey. In concluding his address, which was often cheered, the
Duke told the young able-bodied men that his clerks were ready to
take down the names of all those willing to enlist, and everyone who
would enlist in the 93rd Highlanders, that the clerk would give him,
there and then, £6 sterling; those who would rather enter any other
corps, would get £3, all from his own private purse, independently of
the government bounty. After advancing many silly flattering
decoyments, he sat down to see the result, but there was no
movement among the people; after sitting for a long time looking at
the clerks, and they at him, at last his anxious looks at the people
assumed a somewhat indignant appearance, when he suddenly rose
up and asked what was the cause of their non-attention to the
proposals he made, but no reply; it was the silence of the grave. Still
standing, his Grace suddenly asked the cause; but no reply; at last
an old man, leaning upon his staff, was observed moving towards
the Duke, and when he approached near enough, he addressed his
Grace something as follows: ‘I am sorry for the response your
Grace’s proposals are meeting here to-day, so near the spot where
your maternal grandmother, by giving forty-eight hours’ notice,
marshalled fifteen hundred men to pick out of them the nine
hundred she required, but there is a cause for it, and a grievous
cause, and as your Grace demands to know it, I must tell you, as I
see no one else are inclined in this assembly to do it. Your Grace’s
mother and predecessors applied to our fathers for men upon former
occasions, and our fathers responded to their call; they have made
liberal promises, which neither them nor you performed; we are, we
think, a little wiser than our fathers, and we estimate your promises
of to-day at the value of theirs, besides you should bear in mind that
your predecessors and yourself expelled us in a most cruel and
unjust manner from the land which our fathers held in lien from your
family, for their sons, brothers, cousins, and relations, which were
handed over to your parents to keep up their dignity, and to kill the
Americans, Turks, French, and the Irish; and these lands are
devoted now to rear dumb brute animals, which you and your
parents consider of far more value than men. I do assure your Grace
that it is the prevailing opinion in this county, that should the Czar of
Russia take possession of Dunrobin Castle and of Stafford House
next term, that we could not expect worse treatment at his hands,
than we have experienced at the hands of your family for the last
fifty years. Your parents, yourself, and your commissioners, have
desolated the glens and straths of Sutherland, where you should find
hundreds, yea, thousands of men to meet you, and respond
cheerfully to your call, had your parents and yourself kept faith with
them. How could your Grace expect to find men where they are not,
and the few of them which are to be found among the rubbish or
ruins of the county, has more sense than to be decoyed by chaff to
the field of slaughter; but one comfort you have, though you cannot
find men to fight, you can supply those who will fight with plenty of
mutton, beef, and venison.’ The Duke rose up, put on his hat, and
left the field.”
Whether my correspondent added to the old man’s reply to his Grace
or not, I cannot say, but one thing is evident, it was the very reply
his Grace deserved.
I know for a certainty this to be the prevailing feeling throughout the
whole Highlands of Scotland, and who should wonder at it? How
many thousands of them who served out their 21, 22, 25, and 26
years, fighting for the British aristocracy, and on their return—
wounded, maimed, or worn out—to their own country, promising
themselves to spend the remainder of their days in peace, and
enjoying the blessings and comfort their fathers enjoyed among
their Highland, healthy, delightful hills, but found to their grief, that
their parents were expelled from the country to make room for
sheep, deer, and game, the glens where they were born, desolate,
and the abodes which sheltered them at birth, and where they were
reared to manhood, burnt to the ground; and instead of meeting the
cheers, shaking-hands, hospitality, and affections of fathers,
mothers, brothers, sisters, and relations, met with desolated glens,
bleating of sheep, barking of dogs; and if they should happen to rest
their worn-out frame upon the green sod which has grown upon
their father’s hearth, and a gamekeeper, factor, or water bailiff, to
come round, he would very unceremoniously tell them to absent
themselves as smart as they could, and not to annoy the deer. No
race on record has suffered so much at the hands of those who
should be their patrons, and proved to be so tenacious of patriotism
as the Celtic race, but I assure you it has found its level now, and
will disappear soon altogether; and as soon as patriotism shall
disappear in any nation, so sure that nation’s glory is tarnished,
victories uncertain, her greatness diminished, and decaying
consumptive death will be the result. If ever the old adage, which
says, “Those whom the gods determine to destroy, they first deprive
them of reason,” was verified, it was, and is, in the case of the
British aristocracy, and Highland proprietors in particular. I am not so
void of feeling as to blame the Duke of Sutherland, his parents, or
any other Highland absentee proprietor for all the evil done in the
land, but the evil was done in their name, and under the authority
they have invested in wicked, cruel servants. For instance, the only
silly man who enlisted from among the great assembly which his
Grace addressed, was a married man, with three of a family and his
wife; it was generally believed that his bread was baked for life, but
no sooner was he away to Fort George to join his regiment, than his
place of abode was pulled down, his wife and family turned out, and
only permitted to live in a hut, from which an old female pauper was
carried a few days before to the churchyard; there the young family
were sheltered, and their names registered upon the poor roll for
support; his Grace could not be guilty of such low rascality as this,
yet he was told of it, but took no cognisance of those who did it in
his name. It is likewise said that this man got a furlough of two
weeks to see his wife and family before going abroad, and that
when the factor heard he was coming, he ordered the ground officer
of the parish of Rogart, named MacLeod, to watch the soldier, and
not allow him to see nor speak to his wife, but in his (the officer’s)
presence. We had at the same time, in the parish, an old bachelor of
the name of John Macdonald, who had three idiot sisters, whom he
upheld, independent of any source of relief; but a favourite of
George, the notorious factor, envied this poor bachelor’s farm, and
he was summoned to remove at next term. The poor fellow
petitioned his Grace and Loch, but to no purpose; he was doomed to
walk away on the term day, as the factor told him, “to America,
Glasgow, or to the devil if he choosed.” Seeing he had no other
alternative, two days before the day of his removal he yoked his
cart, and got neighbours to help him to haul the three idiots into it,
and drove away with them to Dunrobin Castle. When he came up to
factor Gunn’s door, he capsized them out upon the green, and
wheeled about and went away home. The three idiots finding
themselves upon the top of one another so sudden, they raised an
inhuman-like yell, fixed into one another to fight, and scratched,
yelled, and screeched so terrific that Mr. Gunn, his lady, his
daughters, and all the clerks and servants were soon about them;
but they hearkened to no reason, for they had none themselves, but
continued their fighting and inharmonious music. Messenger after
messenger was sent after John, but of no use; at last the great
Gunn himself followed and overtook him, asked him how did he
come to leave his sisters in such a state? He replied, “I kept them
while I had a piece of land to support them; you have taken that
land from me, then take them along with the land, and make of
them what you can; I must look out for myself, but I cannot carry
them to the labour market.” Gunn was in a fix, and had to give John
assurance that he would not be removed if he would take his sisters,
so John took them home, and has not been molested as yet.
I have here beside me (in Canada) a respectable girl of the name of
Ann Murray, whose father was removed during the time of the
wholesale faggot removals, but got a lot of a barren moor to
cultivate. However barren-like it was, he was raising a family of
industrious young sons, and by dint of hard labour and
perseverance, they made it a comfortable home; but the young sons
one by one left the country (and four of them are within two miles of
where I sit); the result was, that Ann was the only one who
remained with the parents. The mother, who had an attack of palsy,
was left entirely under Ann’s care after the family left; and she took
it so much to heart that her daughter’s attention was required day
and night, until death put an end to her afflictions, after twelve
years’ suffering. Shortly after the mother’s death, the father took ill,
and was confined to bed for nine months; and Ann’s labour re-
commenced until his decease. Though Ann Murray could be
numbered among the most dutiful of daughters, yet her incessant
labour, for a period of more than thirteen years, made visible inroads
upon her tender constitution; yet by the liberal assistance of her
brothers, who did not loose sight of her and their parent (though
upon a foreign strand), Ann Murray kept the farm in the best of
order, no doubt expecting that she would be allowed to keep it after
her parent’s decease, but this was not in store for her; the very day
after her father’s funeral, the officer came to her and told her that
she was to be removed in a few weeks, that the farm was let to
another, and that Factor Gunn wished to see her. She was at that
time afflicted with jaundice, and told the officer she could not
undertake the journey, which was only ten miles. Next day the
officer was at her again, more urgent than before, and made use of
extraordinary threats; so she had to go. When she appeared before
this Bashaw, he swore like a trooper, and damned her soul, why she
disobeyed his first summons; she excused herself, trembling, that
she was unwell; another volley of oaths and threats met her
response, and told her to remove herself from the estate next week,
for her conduct; and with a threat, which well becomes a Highland
tyrant, not to take away, nor sell a single article of furniture,
implements of husbandry, cattle, or crop; nothing was allowed but
her own body clothes; everything was to be handed over to her
brother, who was to have the farm. Seeing there was neither mercy
nor justice for her, she told him the crop, house, and every other
thing belonging to the farm, belonged to her and her brothers in
America, and that the brother to whom he (the factor) intended to
hand over the farm and effects never helped her father or mother
while in trouble; and that she was determined that he should not
enjoy what she laboured for, and what her other brothers paid for.
She went and got the advice of a man of business, advertised a sale,
and sold off, in the face of threats of interdict, and came to Canada,
where she was warmly received by brothers, sisters, and friends,
now in Woodstock, and can tell her tale better than I can. No one
could think nor believe that his Grace would ever countenance such
doings as these; but it was done in his name.
I have here within ten miles of me, Mr. William Ross, once taxman of
Achtomleeny, Sutherlandshire, who occupied the most convenient
farm to the principal deer-stalking hills in the county. Often have the
English and Irish lords, connected in marriage with the Sutherlands,
dined and took their lunch at William Ross’s table, and at his
expense; and more than once passed the night under his roof. Mr.
Ross being so well acquainted among the mountains and haunts of
the deer, was often engaged as a guide and instructor to these
noblemen on their deer-stalking and fishing excursions, and became
a real favourite with the Sutherland family, which enabled him to
erect superior buildings to the common rule, and improve his farm in
a superior style; so that his mountain-side farm was nothing short of
a Highland paradise. But unfortunately for William, his nearest
neighbour, one Major Gilchrist, a sheep farmer, coveted Mr. Ross’s
vineyard, and tried many underhand schemes to secure the place for
himself, but in vain. Ross would hearken to none of his proposals.
But Ahab was a chief friend of Factor Gunn; and William Ross got
notice of removal. Ross prepared a memorial to the first and late
Duchess of Sutherland, and placed it in her own hand. Her Grace
read it, instantly went into the factor’s office, and told him that
William Ross was not to be removed from Achtomleeny while he
lived; and wrote the same on the petition, and handed it back to
Ross, with a graceful smile, saying, “You are now out of the reach of
factors; now, William, go home in peace.” William bowed, and
departed cheerfully; but the factor and ground-officer followed close
behind him, and while Ross was reading her Grace’s deliverance, the
officer, David Ross, came and snapped the paper out of his hand,
and ran to Factor Gunn with it. Ross followed, but Gunn put it in his
pocket, saying, “William, you would need to give it to me afterwards,
at any rate, and I will keep it till I read it, and then return it to you,”
and with a tiger-like smile on his face, said, “I believe you came
good speed to-day, and I am glad of it;” but William never got it in
his hand again. However, he was not molested during her Grace’s
life. Next year she paid a visit to Dunrobin Castle, when Factor
William Gunn advised Ross to apply to her for a reduction of rent,
under the mask of favouring him. He did so, and it was granted
cheerfully. Her Grace left Dunrobin that year never to return; in the
beginning of the next spring she was carried back to Dunrobin a
corpse, and a few days after was interred in Dornoch. William Ross
was served with a summons of removal from Achtomleeny, and he
had nothing to show. He petitioned the present Duke, and his
commissioner, Mr. Loch, and related the whole circumstances to
them, but to no avail, only he was told that Factor Gunn was ordered
to give him some other lot of land, which he did: and having no
other resource, William accepted of it to his loss; for between loss of
cattle, building and repairing houses, he was minus one hundred and
fifty pounds sterling, of his means, and substance, from the time he
was removed from Achtomleeny till he removed himself to Canada.
Besides, he had a written agreement or promise for melioration or
valuation for all the farm improvements and house building at
Achtomleeny, which was valued by the family surveyor at £250.
William was always promised to get it, until they came to learn that
he was leaving for America, then they would not give him a cent.
William Ross left them with it to join his family in Canada; but he
can in his old age sit at as comfortable a table, and sleep on as
comfortable a bed, with greater ease of mind and a clearer
conscience, among his own dutiful and affectionate children, than
the tyrant factor ever did, or ever will among his. I know as well as
any one can tell me, that this is but one or two cases out of the
thousand I could enumerate, where the liberality and benevolence of
his Grace, and of his parents, were abused, and that to their patron’s
loss. You see in the above case that William was advised to plead for
a reduction of rent, so that the factor’s favourite, Ahab Gilchrist,
would have the benefit of Naboth Ross’s improvement, and the
reduction he got on his rent, which would not be obtained
otherwise.
The unhallowed crew of factors and officials, from the highest to the
lowest grade, employed by the family of Sutherland, got the corrupt
Welcome to our website – the ideal destination for book lovers and
knowledge seekers. With a mission to inspire endlessly, we offer a
vast collection of books, ranging from classic literary works to
specialized publications, self-development books, and children's
literature. Each book is a new journey of discovery, expanding
knowledge and enriching the soul of the reade
Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.
ebookluna.com