SlideShare a Scribd company logo
(eBook PDF) Introduction to Programming with
Java: A Problem Solving Approach 3rd Edition
download
https://ebookluna.com/product/ebook-pdf-introduction-to-
programming-with-java-a-problem-solving-approach-3rd-edition/
Download full version ebook from https://ebookluna.com
John Dean
Park University
Raymond Dean
University of Kansas
JAVA
WITH
A Problem Solving Approach
Introduction to Programming
dea75768_fm_i-xxxviii.indd 1 4/30/20 11:54 AM
12.10. Empty Statement 552
12.11. Using break to Exit from a Loop 554
12.12. for Loop Header Details 555
12.13. Enumerated Types 557
12.14. forEach Method, Lambda Expressions,
Method References, and Streams 564
12.15. Hexadecimal, Octal, and Binary
Numbers 573
12.16. GUI Track: Unicode (Optional) 574
12.17. Introduction to GridWorld Case Study
(Optional) 579
CHAPTER 13
Aggregation, Composition,
and Inheritance 591
13.1. Introduction 592
13.2. Composition and Aggregation 592
13.3. Inheritance Overview 599
13.4. Implementation of a Person/Employee/
FullTime Hierarchy 603
13.5. Constructors in a Subclass 605
13.6. Method Overriding 606
13.7. Using the Person/Employee/FullTime
Hierarchy 609
13.8. The final Access Modifier 610
13.9. Using Inheritance with Aggregation and
Composition 610
13.10. Design Practice with Card Game
Example 613
13.11. GridWorld Case Study Extensions
(Optional) 619
13.12. Problem Solving with Association Classes
(Optional) 626
CHAPTER 14
Inheritance and Polymorphism 637
14.1. Introduction 638
14.2. The Object Class and Automatic Type
Promotion 638
14.3. The equals Method 639
14.4. The toString Method 643
14.5. Polymorphism and Dynamic Binding 648
14.6. Assignments When the Two Sides’ Classes
Are Different 653
14.7. Polymorphism with Arrays 654
14.8. abstract Methods and Classes 660
14.9. Interfaces 663
14.10. The protected Access Modifier 673
14.11. GUI Track: Three-Dimensional Graphics
(Optional) 677
CHAPTER 15
Exception Handling 691
15.1. Introduction 692
15.2. Overview of Exceptions and Exception
Messages 692
15.3. Using try and catch Blocks to Handle
“Dangerous” Method Calls 693
15.4. Line Plot Example 695
15.5. try Block Details 699
15.6. Two Categories of Exceptions—Checked and
Unchecked 700
15.7. Unchecked Exceptions 702
15.8. Checked Exceptions 705
15.9. Generic catch Block with Exception
Class 708
15.10. Multiple catch Blocks and Multiple
Exceptions per Block 712
15.11. Understanding Exception Messages 714
15.12. Using a throws Clause to Postpone the
catch 718
15.13. Automatic Cleanup Using Try-With-
Resources 720
15.14. GUI Track: Line Plot Example Revisited
(Optional) 722
CHAPTER 16
Files, Buffers, Channels, and Paths 735
16.1. Introduction 736
16.2. Simple Text-File Example: HTML
File Generator 737
16.3. A Website Reader 741
16.4. Object File I/O 743
16.5. Character Sets and File-Access
Options 748
16.6. Buffered Text File I/O 749
16.7. Primitive Buffers with Random Access 752
16.8. Channel I/O and Memory-Mapped Files 760
viii Contents
dea75768_fm_i-xxxviii.indd 8 4/30/20 11:54 AM
16.9. Path, Whole-File, and Directory
Operations 767
16.10. Walking a Directory Tree 769
16.11. GUI Track: Final Iteration of Problem
Solving with CRC Cards (Optional) 775
CHAPTER 17
GUI Programming Basics 787
17.1. Introduction 788
17.2. SimpleWindow Program 791
17.3. Stage and Scene 794
17.4. JavaFX Components 796
17.5. Label Control 797
17.6. TextField Control 799
17.7. Greeting Program 801
17.8. Event Handling 805
17.9. Property Binding 809
17.10. JavaFX CSS 812
17.11. Scene Graph Inheritance 818
17.12. Style Sheets and Cascading 821
17.13. Button Control and FactorialButton
Program 826
17.14. Distinguishing Between Multiple Events 832
17.15. Colors 834
17.16. ColorChooser Program 838
CHAPTER 18
GUI Programming—Layout Panes 849
18.1. Introduction 849
18.2. Layout Panes 851
18.3. FlowPane and GridPane—Competing
Layout Philosophies 853
18.4. VBox Program with Two Stages and an
Image File 858
18.5. BorderPane 867
18.6. TilePane and TextFlow Containers 872
18.7. TicTacToe Program 878
18.8. Embedded Panes, HBox, and MathCalculator
Program 882
18.9. Plain Pane Container and Component
Positioning 889
CHAPTER 19
GUI Programming—Additional GUI
Components, Additional Event Handlers,
Animation 896
19.1. Introduction 897
19.2. User Interface Design 897
19.3. TextArea Control 898
19.4. CheckBox and RadioButton Controls 903
19.5. ComboBox Control 909
19.6. Job Application Program 913
19.7. ScrollPane and Menu Classes 918
19.8. Images and Mouse Events 922
19.9. Lunar Eclipse Program with Circle,
RadialGradient, and Slider 928
19.10. Animation 933
Appendices
Appendix 1	
ASCII Character Set 943
Appendix 2 Operator Precedence 945
Appendix 3 Java Keywords and Other Reserved
Words 947
Appendix 4 Packages and Modules 951
Appendix 5 Java Coding-Style Conventions 963
Appendix 6 Javadoc with Tags 975
Appendix 7 UML Diagrams 980
Appendix 8	
Number Systems and Conversions
Between Them 986
Additional Online Material
Chapter S6	
Writing Methods in a Non-Object-
Oriented Environment
Chapter S9	
Arrays in a Non-Object-Oriented
Environment
Chapter S17	
GUI Programming Basics
Chapter S18	
GUI Programming—Component
Layout, Additional GUI Components
Appendix 9 Multithreading
Index 990
Contents ix
dea75768_fm_i-xxxviii.indd 9 5/12/20 1:41 PM
x
In this book, we lead you on a journey into the fun and exciting world of computer programming. Through-
out your journey, we’ll provide you with lots of problem-solving practice. After all, good programmers
need to be good problem solvers. We’ll show you how to implement your problem solutions with Java
programs. We provide a plethora of examples, some short and focused on a single concept, some longer and
more “real world.” We present the material in a conversational, easy-to-follow manner aimed at making
your journey a pleasant one. When you’re done with the book, you should be a proficient Java programmer.
Our textbook targets a wide range of readers. Primarily, it targets students in a standard college-level
“Introduction to Programming” course or course sequence where no prerequisite programming experience
is assumed. We have included the topics recommended by the College Board for high school students
studying for advanced placement (AP) in computer science. So this text should be good for those students
as well.
In addition to targeting students with no prerequisite programming experience, our textbook targets
industry practitioners and college-level students who have some programming experience and want to
learn Java. This second set of readers can skip the early chapters on general programming concepts and
focus on the features of Java that differ from the languages that they already know. In particular, because
C++ and Java are similar, readers with a C++ background should be able to cover the textbook in a single
three-credit-hour course. (But we should reiterate for those of you with no programming experience:
No prerequisite programming experience is required in order to use this text.)
Finally, our textbook targets those who are learning Java on their own, outside of a classroom environ-
ment. This third set of readers should read the entire textbook at a pace determined on a case-by-case basis.
What’s New in This Edition?
The changes in this edition are big and small. Big changes include new chapters, reorganized chapter sec-
tions, new programming constructs, new program examples, and new exercises. Smaller changes include
updating explanations and anecdotes. We’ve combed the entire book for opportunities to improve the
book’s clarity and readability. The following list highlights the more significant changes that we’ve made
to this edition.
∙ Introductory Chapter
	
To keep up with the computer industry’s growth, we’ve made quite a few changes to Chapter 1, such
as updating the information in the computer hardware and Java history sections.
∙ Switching Constructs
	
Java 12 and Java 13 made improvements to the venerable switch statement, and this edition describes
those improvements. We use the new switching techniques (multiple comma-­
separated case constants
and no break statements) for programs throughout the book. And we use switch statements versus
switch expressions according to what the problem calls for. If you’re a fan of the old-style switch
statement, no worries, we provide a description early on which will help you with legacy code.
Preface
dea75768_fm_i-xxxviii.indd 10 4/30/20 11:54 AM
Preface xi
∙ Local Variable Type Inferencing
	
Java 10 introduced the ability to use var as a type (rather than int, double, etc.) for a local variable
declaration where the declaration is part of an initialization. We describe the new syntax, but for self-
documentation reasons, we stick with traditional explicit type declarations for the most part.
∙ Name Change for Static Variables and Static Methods
	
The powers that be (the Oracle documentation folks) now use the terms static variable and static
method for what used to be known as class variable and class method, so we’ve updated accordingly.
∙ Miscellaneous Java API Library Updates
	
With the new Java releases since the second edition, there have been quite a few updates to the Java
API library. We’ve updated our discussions and programs with new API method and constructor calls
when appropriate. Most of our new API content can be found in our GUI coverage, but there are other
API changes sprinkled throughout the book. For example, with Java’s deprecation of the wrapper
class constructors, we’ve refactored our programs to rely on the wrapper classes’ valueOf methods.
∙ New Section—forEach Method and Streams
	
We introduce the forEach method as a simple alternative to the for-each loop in the context of an
ArrayList. We then use the forEach method in the context of streams, where it really shines. We
describe streams in depth, with their exciting potential to take advantage of parallel processing to
improve a program’s efficiency.
∙ Lambda Expressions and Method References
	
Lambda expressions and method references are techniques that allow you to implement the function-
ality of a method so you can use it as an argument in a method call. We first present lambda expres-
sions and method references as arguments for a forEach method call. Later, we use lambda expressions
and method references extensively to help with the GUI programs.
∙ Interfaces with Static Methods and Default Methods
	
We’ve rewritten Chapter 14’s section on interfaces to include a discussion of static methods and
default methods. Oracle added them to interfaces because they support an interface’s ability to imple-
ment multiple inheritance effectively.
∙ End-of-Chapter GUI Sections
	
We’ve rewritten all of our end-of-chapter GUI sections to take advantage of Java’s newer GUI constructs.
∙ Three New Chapters—JavaFX
	
In this book’s second edition, we used the AWT and Swing platforms for our two GUI chapters. This
third edition moves those chapters to the book’s website. We provide three new chapters in the main
body of the book that describe GUI programming using the JavaFX platform. As part of that presenta-
tion, you’ll learn how to format your programs using JavaFX CSS properties.
∙ New Appendix—Modules
	
In Appendix 4, we introduce modules, which allow you to group together packages. Modules make it
easier to organize and share classes for different programming needs. They are used to facilitate the
configuration of Java software for diverse hardware and software platforms.
dea75768_fm_i-xxxviii.indd 11 5/10/20 8:49 PM
xii Preface
∙ New Exercises
	
We have substantially changed most of the exercises and altered almost all of them in some way. As
before, we provide exercise solutions on the password-protected instructor’s portion of the book’s
website.
Compliant with the College Board’s AP
Computer Science A Curriculum
We have put a great deal of effort into ensuring that this textbook is compliant with the College Board’s
Advanced Placement (AP) Computer Science A curriculum content. It follows all the AP Computer
Science A guidelines. As such, it appears on the College Board’s approved textbook list at
https://apcentral.collegeboard.org/courses/ap-computer-science-a/course-audit.
Textbook Cornerstone #1: Problem Solving
Being able to solve problems is a critical skill that all programmers must possess. We teach programmatic
problem solving by emphasizing two of its key elements—algorithm development and program design.
Emphasis on Algorithm Development
In Chapter 2, we immerse readers into algorithm development by using pseudocode for the algorithm
examples instead of Java. In using pseudocode, students are able to work through nontrivial problems on
their own without getting bogged down in Java syntax—no need to worry about class headings, semico-
lons, braces, and so on.1
Working through nontrivial problems enables students to gain an early apprecia-
tion for creativity, logic, and organization. Without that appreciation, Java students tend to learn Java
syntax with a rote-memory attitude. But with that appreciation, students tend to learn Java syntax more
quickly and effectively because they have a motivational basis for learning it. In addition, they are able to
handle nontrivial Java homework assignments fairly early because they have prior experience with simi-
larly nontrivial pseudocode homework assignments.
In Chapter 3 and in later chapters, we rely primarily on Java for algorithm-development examples. But
for the more involved problems, we sometimes use high-level pseudocode to describe first-cut proposed
solutions. Using pseudocode enables readers to bypass syntax details and focus on the algorithm portion
of the solution.
Emphasis on Program Design
Problem solving is more than just developing an algorithm. It also involves figuring out the best imple-
mentation for the algorithm. That’s program design. Program design is extremely important, and that’s
why we spend so much time on it. Frequently, we explain the thought processes that a person might go
through when coming up with a solution. For example, we explain how to choose between different loop
types, how to split up a method into multiple methods, how to decide on appropriate classes, how to
1
Inevitably, we use a particular style for our pseudocode, but we repeatedly emphasize that other pseudocode styles are fine so long
as they convey the intended meaning. Our pseudocode style is a combination of free-form description for high-level tasks and more
specific commands for low-level tasks. We’ve chosen a pseudocode style that is intuitive, to welcome new programmers, and struc-
tured, to accommodate program logic.
dea75768_fm_i-xxxviii.indd 12 4/30/20 11:54 AM
Preface xiii
choose between instance and static members, and how to determine class relationships using inheritance
and composition. We challenge students to find the most elegant implementations for a particular task.
We devote a whole chapter to program design—Chapter 8, “Software Engineering.” In that chapter,
we provide an in-depth look at coding-style conventions and documentation for programmers and users.
We discuss design strategies like separation of concerns, modularization, and encapsulation. Also in the
chapter, we describe alternative design strategies—top-down, bottom-up, case-based, and iterative
enhancement.
Problem-Solving Sections
We often address problem solving (algorithm development and program design) in the natural flow of
explaining concepts. But we also cover problem solving in sections that are wholly devoted to it. In each
problem-solving section, we present a situation that contains an unresolved problem. In coming up with a
solution for the problem, we try to mimic the real-world problem-solving experience by using an iterative
design strategy. We present a first-cut solution, analyze the solution, and then discuss possible improve-
ments to it. We use a conversational trial-and-error format (e.g., “What type of layout manager should
we use? We first tried the GridLayout manager. That works OK, but not great. Let’s now try the
BorderLayout manager.”). This casual tone sets the student at ease by conveying the message that it is
normal, and in fact expected, that a programmer will need to work through a problem multiple times
before finding the best solution.
Additional Problem-Solving Mechanisms
We include problem-solving examples and problem-solving advice throughout the text (not just in
Chapter 2, Chapter 8, and the problem-solving sections). As a point of emphasis, we insert a problem-
solving box, with an icon and a succinct tip, next to the text that contains the problem-solving example
and/or advice.
We are strong believers in learning by example. As such, our textbook contains a multitude of com-
plete program examples. Readers are encouraged to use our programs as recipes for solving similar pro-
grams on their own.
Textbook Cornerstone #2: Fundamentals First
Postpone Concepts That Require Complex Syntax
We feel that many introductory programming textbooks jump too quickly into concepts that require com-
plex syntax. In using complex syntax early, students get in the habit of entering code without fully under-
standing it or, worse yet, copying and pasting from example code without fully understanding the example
code. That can lead to less-than-ideal programs and students who are limited in their ability to solve a wide
variety of problems. Thus, we prefer to postpone concepts that require complex syntax. We prefer to intro-
duce such concepts later on, when students are better able to understand them fully.
As a prime example of that philosophy, we cover the simpler forms of GUI programming early (in
an optional graphics track), but we cover the more complicated forms of GUI programming later in the
book. Specifically, we postpone event-driven GUI programming until the end of the book. This is dif-
ferent from some other Java textbooks, which favor early full immersion into event-driven GUI pro-
gramming. We feel that strategy is a mistake because proper event-driven GUI programming requires a
great deal of programming maturity. When they learn it at the end of the book, our readers are better
able to understand it fully.
dea75768_fm_i-xxxviii.indd 13 4/30/20 11:54 AM
xiv Preface
Tracing Examples
To write code effectively, it’s imperative to understand code thoroughly. We’ve found that step-by-step
tracing of program code is an effective way to ensure thorough understanding. Thus, in the earlier parts of
the textbook, when we introduce a new programming structure, we often illustrate it with a meticulous
trace. The detailed tracing technique we use illustrates the thought process programmers employ while
debugging. It’s a printed alternative to the sequence of screen displays generated by debuggers in inte-
grated development environment (IDE) software.
Input and Output
In the optional GUI-track sections and in the GUI chapters at the end of the book, we use GUI commands
for input and output (I/O). But because of our emphasis on fundamentals, we use console commands for
I/O for the rest of the book.2
For console input, we use the Scanner class. For console output, we use the
standard System.out.print, System.out.println, and System.out.printf methods.
Textbook Cornerstone #3: Real World
More often than not, today’s classroom students and industry practitioners prefer to learn with a hands-
on, real-world approach. To meet this need, our textbook and its associated website include:
∙ compiler tools
∙ complete program examples
∙ practical guidance in program design
∙ coding-style guidelines based on industry standards
∙ Unified Modeling Language (UML) notation for class relationship diagrams
∙ practical homework-project assignments
Compiler Tools
We do not tie the textbook to any particular compiler tool—you are free to use any compiler tool(s) that you
like. If you do not have a preferred compiler in mind, then you might want to try out one or more of these:
∙ Java Standard Edition Development Kit (JDK), by Oracle
∙ TextPad, by Helios
∙ Eclipse, by the Eclipse Foundation
∙ Netbeans, backed by Oracle
∙ BlueJ, by the University of Kent and Deaken University
To obtain the above compilers, visit our textbook website at http://www.mhhe.com/dean3e, find the
appropriate compiler link(s), and download away for free.
Complete Program Examples
In addition to providing code fragments to illustrate specific concepts, our textbook contains lots of com-
plete program examples. With complete programs, students are able to (1) see how the analyzed code ties
in with the rest of a program, and (2) test the code by running it.
2
We introduce GUI I/O at the end of Chapter 3 with dialog boxes. That opens up an optional door for GUI fans. If readers are so
inclined, they can use the Alert, TextInputDialog, and ChoiceDialog classes to implement all our programs with GUI
I/O rather than console I/O.
dea75768_fm_i-xxxviii.indd 14 4/30/20 11:54 AM
Preface xv
Coding-Style Conventions
We include coding-style tips throughout the textbook. The coding-style tips are based on Oracle’s coding
conventions (https://www.oracle.com/technetwork/java/codeconvtoc-136057.html), Google’s coding con-
ventions (https://google.github.io/styleguide/javaguide.html), and industry practice. In Appendix 5, we
provide a complete reference for the book’s coding-style conventions and an associated example program
that illustrates these conventions.
UML Notation
UML has become a standard for describing the entities in large software projects. Rather than overwhelm
beginning programmers with syntax for the entire UML (which is quite extensive), we present a subset of
UML. Throughout the textbook, we incorporate UML notation to represent classes and class relationships
pictorially. For those interested in more details, we provide additional UML notation in Appendix 7.
Homework Problems
We provide homework problems that are illustrative, practical, and clearly worded. The problems range
from easy to challenging. They are grouped into three categories—review questions, exercises, and proj-
ects. We include review questions and exercises at the end of each chapter, and we provide projects on our
textbook’s website.
The review questions tend to have short answers, and the answers are in the textbook. The review
questions use these formats: short-answer, multiple-choice, true/false, fill-in-the-blank, tracing,
debugging, and write a code fragment. Each review question is based on a relatively small part of the
chapter.
The exercises tend to have short to moderate-length answers, and the answers are not in the textbook.
The exercises use these formats: short-answer, tracing, debugging, and write a code fragment. Exercises
are keyed to the highest prerequisite section number in the chapter, but they sometimes integrate concepts
from several parts of the chapter. For this third edition, we have changed almost all of the end-of-chapter
exercises, including exercises associated with unchanged material in the body of the text.
The projects consist of problem descriptions whose solutions are complete programs. Project solu-
tions are not in the textbook. Projects require students to employ creativity and problem-solving skills and
apply what they’ve learned in the chapter. These projects often include optional parts, which provide chal-
lenges for the more talented students. Projects are keyed to the highest prerequisite section number in the
chapter, but they often integrate concepts from several preceding parts of the chapter. For this third edition,
we have modified old projects and added new projects to make all projects conform to content in the body
of the current text. Because the most substantial body-of-text changes are in the final three chapters, most
of the project modifications and additions are associated with these chapters.
An important special feature of this book is the way that it specifies problems. “Sample sessions”
show the precise output generated for a particular set of input values. These sample sessions include inputs
that represent typical situations and sometimes also extreme or boundary situations.
Academic-Area Projects
To enhance the appeal of projects and to show how the current chapter’s programming techniques might
apply to different areas of interest, we take project content from several academic areas:
∙ computer science and numerical methods
∙ business and accounting
dea75768_fm_i-xxxviii.indd 15 4/30/20 11:54 AM
xvi Preface
∙ social sciences and statistics
∙ math and physics
∙ engineering and architecture
∙ biology and ecology
Most of the academic-area projects do not require prerequisite knowledge in a particular area. Thus,
instructors are free to assign almost any of the projects to any of their students. To provide a general reader
with enough specialized knowledge to work a problem in a particular academic area, we sometimes expand
the problem statement to explain a few special concepts in that academic area.
Most of the academic-area projects do not require students to have completed projects from earlier
chapters; that is, most projects do not build on previous projects. Thus, for the most part, instructors are
free to assign projects without worrying about prerequisite projects. In some cases, a project repeats a
previous chapter’s project with a different approach. The teacher may elect to take advantage of this rep-
etition to dramatize the availability of alternatives, but this is not necessary.
Project assignments can be tailored to fit readers’ needs. For example:
∙ For readers outside of academia—
Readers can choose projects that match their interests.
∙ When a course has students from one academic area—
Instructors can assign projects from the relevant academic area.
∙ When a course has students with diverse backgrounds—
	
Instructors can ask students to choose projects from their own academic areas, or instructors can
ignore the academic-area delineations and simply assign projects that are most appealing.
To help you decide which projects to work on, we’ve included a “Project Summary” section after the
preface. It lists all the projects by chapter and section, and for each project, it specifies:
∙ prerequisite chapter and section
∙ academic area
∙ estimated difficulty
∙ a title and brief description
After using the “Project Summary” section to get an idea of which projects you might like to work on, see
the textbook’s website for the full project descriptions.
Organization
In writing this book, we lead readers through three important programming methodologies: structured
programming, OOP, and event-driven programming. For our structured programming coverage, we intro-
duce basic concepts such as variables and operators, if statements, and loops. Then we show readers how
to call prebuilt methods from Oracle’s Java API library. Many of these methods, like those in the Math
class, are non-OOP methods that can be called directly. Others, like those in the String class, are OOP
methods that must be called by a previously created object. After an “interlude” that gives readers a brief
taste of what it’s like to write methods in a non-OOP environment, we move into OOP programming, and
introduce basic OOP concepts such as classes, objects, instance variables, instance methods, and construc-
tors. We also introduce static variables and static methods, which are useful in certain situations. However,
we note that they should be used less often than instance variables and instance methods. Next, we move
dea75768_fm_i-xxxviii.indd 16 4/30/20 11:54 AM
Preface xvii
on to more advanced OOP concepts—arrays, collections, interfaces, and inheritance. Chapters on excep-
tion handling and files provide a transition into event-driven GUI programming. We describe and employ
event-driven GUI programming in the final three chapters.
The content and sequence we promote enable students to develop their skills from a solid foundation
of programming fundamentals. To foster this fundamentals-first approach, our book starts with a mini-
mum set of concepts and details. It then gradually broadens concepts and adds detail later. We avoid over-
loading early chapters by deferring certain less-important details to later chapters.
GUI Track
Many programmers find Graphical User Interface (GUI) programming to be fun. As such, GUI program-
ming can be a great motivational tool for keeping readers interested and engaged. That’s why we include
graphics sections throughout the book, starting in Chapter 1. We call those sections our “GUI track.” Most
of these end-of-chapter sections use GUI code that complements the current chapter’s previously pre-
sented non-GUI material. For readers who do not have time for the GUI track, no problem. Any or all of
the GUI track sections may be skipped because the rest of the book does not depend on any of the GUI-
track material.
Although the rest of the book does not depend on the GUI-track material, be aware that some of the
GUI-track sections depend on some of the material in prior GUI-track sections:
∙ Chapter 3’s GUI section introduces dialog boxes for user input, and dialog boxes are used in later GUI
sections for Chapters 10, 11, 15, and 16.
∙ Chapters 8, 10, and 16 have GUI sections that implement a common program, with iterative enhance-
ments in each new GUI section.
∙ Chapters 12 and 13 have GUI sections that implement a common GridWorld program (for readers
interested in the College Board’s AP Computer Science A curriculum). The GridWorld code uses
AWT and Swing GUI software.
Chapter 1
In Chapter 1, we first explain basic computer terms—what are the hardware components, what is source
code, what is object code, and so on. We then narrow our focus and describe the programming language
we’ll be using for the remainder of the book—Java. Finally, we give students a quick view of the classic
bare-bones “Hello World” program. We explain how to create and run the program using minimalist­
software—Microsoft’s Notepad text editor and Oracle’s command-line JDK tools.
Chapter 2
In Chapter 2, we present problem-solving techniques with an emphasis on algorithmic design. In imple-
menting algorithm solutions, we use generic tools—flowcharts and pseudocode—with pseudocode given
greater weight. As part of our algorithm-design explanation, we describe structured programming tech-
niques. In order to give students an appreciation for semantic details, we show how to trace algorithms.
Chapters 3–5
We present structured programming techniques using Java in Chapters 3–5. Chapter 3 describes sequential
programming basics—variables, input/output, assignment statements, and simple method calls. Chapter 4
describes nonsequential program flow—if statements, switch constructs, and loops. In Chapter 5, we
explain methods in more detail and show readers how to use prebuilt methods in the Java API library.
dea75768_fm_i-xxxviii.indd 17 4/30/20 11:54 AM
xviii Preface
In all three chapters, we teach algorithm design by solving problems and writing programs with the newly
introduced Java syntax.
Interlude
This “mini-chapter” contains two programs that show how to write multiple methods without using OOP.
The Interlude presents a fork in the road between two study sequences. For the standard study sequence,
read the chapters in the standard order (Chapters 1 through 19). For the “objects later” study sequence,
after reading Chapter 5, read the supplemental chapters S6 and S9 online before returning to Chapter 6,
where you’ll begin your study of OOP in earnest.
Chapters 6–7
Chapter 6 introduces the basic elements of OOP in Java. This includes implementing classes and imple-
menting methods and variables within those classes. We use UML class diagrams and object-oriented
tracing techniques to illustrate these concepts.
Chapter 7 provides additional OOP details. It explains how reference variables are assigned, tested for
equality, and passed as arguments to a method. It explains overloaded methods and constructors. It also
explains the use of static variables, static methods, and different types of named constants.
Chapter 8
While the art of program design and the science of computerized problem-solving are developed through-
out the textbook, in Chapter 8, we focus on these aspects in the context of OOP. This chapter begins with
an organized treatment of programming style. It introduces javadoc, the Java application that automati-
cally generates documentation for user-programmers. It describes ways to communicate with users who
are not programmers. It describes organizational strategies like separation of concerns, modularization,
encapsulation, and provision of general-purpose utilities. Coded examples show how to implement these
strategies. It describes the major programming paradigms—top-down design, bottom-up design, using
pre-written software for low-level modules, and prototyping.
Chapters 9–10
Chapter 9 describes arrays, including arrays of primitives, arrays of objects, and multidimensional arrays.
It illustrates array use with complete programs that sort, search, and construct histograms. Chapter 10
describes Java’s powerful array alternative, ArrayList. This provides a simple example of generic-­element
specification. It also introduces the Java Collections Framework, which in turn, provides natural illustrations
of Java interfaces. The prewritten classes in the Java Collections Framework provide a simple introduction of
sets, maps, and queues. A relatively short but complete program shows how the pre-written Java implementa-
tions of these data structures can be used to create and traverse a multiconnected random network.
Chapter 11
Chapter 11 describes another way to process a collection of data—recursion. This chapter includes a
­
discussion of various recursive strategies. It introduces recursion with a real-life example and a familiar
problem that one can solve easily with either looping or recursion. Then it moves gradually to problems
that are harder to solve with looping and more easily solved with recursion. Although this chapter
appears after the chapter on ArrayLists and the Java Collections Framework, it does not depend on
these ­
concepts—it uses just ordinary arrays.
dea75768_fm_i-xxxviii.indd 18 5/12/20 1:23 PM
Preface xix
Chapter 12
Early on, students need to be immersed in problem-solving activities. Covering too much syntax detail
early can detract from that objective. Thus, we initially gloss over some less-important syntax details and
come back to those details later in Chapter 12. This chapter provides more details on items such as these:
∙ byte and short primitive types
∙ Unicode character set
∙ type promotions
∙ postfix versus prefix modes for the increment and decrement operators
∙ conditional operator
∙ short-circuit evaluation
∙ enum data type
∙ forEach method
∙ lambda expressions
∙ method references
∙ streams
The chapter ends with a friendly introduction to a relatively large public-domain program called Grid-
World, which the College Board has used for many years as part of its AP Computer Science A course of
study. This gives students a glimpse of how larger programs are organized.
Chapters 13–14
Chapters 13 and 14 describe class relationships in depth with numerous examples. Chapter 13 describes
aggregation, composition, and inheritance. Chapter 14 describes advanced inheritance-related details such
as the Object class, polymorphism, abstract classes, and the finer points of interfaces. An optional section
at the end of Chapter 13 describes an extension of the GridWorld environment introduced in Chapter 12
and provides additional exposure to Java’s legacy AWT and Swing graphics. Exercises in Chapters 13 and
14 relate material in these two chapters to corresponding GridWorld features.
Chapters 15−16
Chapter 15 describes exception handling, and Chapter 16 describes files. We present exception handling
before files because file-handling code requires the use of exception handling. For example, to open a file
one must check for an exception. In addition to simple text I/O, our treatment of files includes buffering,
random access, channeling, and memory mapping.
Chapters 17−19
As in the end-of-chapter GUI sections, Chapters 17−19 present GUI concepts using the JavaFX platform.
But the programming strategies differ. What follows are the strategies used in Chapters 17–19 (which are
different from the strategies used in the end-of-chapter GUI sections). For user input, the programs use the
components TextField, TextArea, Button, RadioButton, CheckBox, ComboBox, ScrollPane, and Menu.
For layout, the programs use the containers FlowPane, VBox, HBox, GridPane, BorderPane, TilePane, and
TextFlow. For formatting, the programs use JavaFX CSS properties.
Depending on how much and what kind of GUI techniques you’re interested in, you can study one or
more of the end-of-chapter GUI sections or skip all of them. That won’t affect your ability to grasp what’s
in Chapters 17−19. If you’re short on time, you can omit all of the book’s GUI material without compro-
mising your understanding of other material in the book.
dea75768_fm_i-xxxviii.indd 19 5/10/20 8:50 PM
xx Preface
Chapters S17−S18
Chapters S17 and S18 (the S’s stand for supplemental) are posted online. They describe the older Java GUI
platforms—AWT and Swing. The trend has been for new Java programs to use JavaFX, and not AWT and
Swing. However, there’s quite a bit of AWT and Swing code currently in production, and that means
there’s still a need for Java programmers to understand the older techniques so they can update and improve
existing code. So if you find yourself in that position, Chapters S17 and S18 are a good starting point for
learning what you need to know.
Appendices
Most of the appendices cover reference material, like the ASCII character set and the operator precedence
table. For this third edition, we have updated Appendix 4 by including a detailed description of Java modules.
Subject-Matter Dependencies and
Sequence-Changing Opportunities
We’ve positioned the textbook’s material in a natural order for someone who wants fundamentals and also wants
an early introduction to OOP. We feel that our order is the most efficient and effective one for learning how to
become a proficient OOP programmer. Nonetheless, we realize that different readers have different content-
ordering preferences. To accommodate those different preferences, we’ve provided some built-in flexibility.
Figure 0.1 illustrates that flexibility by showing chapter dependencies and, more importantly, chapter
­
nondependencies. For example, the arrow between Chapter 3 and Chapter 4 means that Chapter 3 must be read
prior to Chapter 4. Because there are no arrows going out of Chapters 1, 11, and 16 that point to other complete
chapters, you may skip those chapters without losing prerequisite material that later chapters need. We use
rectangles with rounded corners to indicate chapter sections that you may want to read in advance. If you choose
that option, you’ll want to return to the normal chapter sequence after completing the advanced sections.
Here are some sequence-changing opportunities revealed by Figure 0.1:
∙ Readers can skip Chapter 1, “Introduction to Computers and Programming.”
∙ For an earlier introduction to OOP, readers can read the OOP overview section in Chapter 6 after
reading Chapter 1.
∙ Readers can learn OOP syntax and semantics in Chapter 6 after finishing Java basics in Chapter 3.
∙ For additional looping practice, readers can learn about arrays in Chapter 9 after finishing loops in Chapter 4.
∙ Readers can skip Chapter 11, “Recursion,” and Chapter 16, “Files.”
∙ Readers who prefer a late objects approach can postpone reading Chapter 6, “Object-Oriented Pro-
gramming,” by first reading Chapter S6, “Writing Methods in a Non-Object-Oriented Environment,”
Sections 9.1–9.6 (which explain the basics of arrays), and Chapter S9, “Arrays in a Non-Object-
Oriented Environment.”
∙ For GUI programming, readers who prefer the Swing platform should read Chapters S17 and S18.
To support content-ordering flexibility, the book contains “hyperlinks.” A hyperlink is an optional
jump forward from one place in the book to another place. The jumps are legal in terms of prerequisite
knowledge, meaning that the jumped-over (skipped) material is unnecessary for an understanding of the
later material. We supply hyperlinks for each of the nonsequential arrows in Figure 0.1. For example, we
supply hyperlinks that go from Chapter 1 to Chapter 6 and from Chapter 3 to Chapter 12. For each hyperlink
tail end (in the earlier chapter), we tell the reader where they may optionally jump to. For each hyperlink
target end (in the later chapter), we provide an icon at the side of the target text that helps readers find the
place where they are to begin reading.
dea75768_fm_i-xxxviii.indd 20 5/12/20 1:24 PM
Preface xxi
Figure 0.1 Chapter dependencies
Ch 5: Using Prebuilt Methods
Ch 1: Introduction
Ch 2: Algorithms and Design
Ch 3: Java Basics
Ch 4: Control Statements
§6.2 OOP
Overview
§6.1−§6.8 OOP
Basics
§12.6−§12.12 Alternate
Coding Mechanisms
§9.1−§9.6 Arrays
§12.1−§12.5 Type
Details
Interlude
Ch 8: Software Engineering
Ch 6: Object-Oriented Programming
Ch 7: OOP−Additional Details
§11.1−§11.5 Non-
Array Recursion
§9.1−§9.6 Array Basics
Chapter S6: Writing
Methods in a Non-Object-
Oriented Environment
Chapter S9: Arrays in a
Non-Object-Oriented
Environment
Ch 9: Arrays
Ch 10: ArrayList and
Introduction to Java Collections
Framework
Ch 12: Type Details and Alternate
Coding Mechanisms
Ch 11: Recursion
Ch 13: Aggregation, Composition
and Inheritance
Ch 16: Files
Ch 14: Inheritance and
Polymorphism
Ch 15: Exception
Handling
Ch S17: Swing GUI
Programming Basics
Ch 17: GUI Programming Basics
Ch 18: GUI Programming—
Layout Panes
Ch 19: GUI Programming—
Additional GUI Components,
Additional Event Handlers, Animation
Ch S18: Swing GUI
Component Layout,
Additional GUI Components
dea75768_fm_i-xxxviii.indd 21 4/30/20 11:54 AM
xxii Preface
Pedagogy
Icons
Program elegance.

Indicates that the associated text deals with a program’s coding style, readability, maintainability,
robustness, and scalability. Those qualities comprise a program’s elegance.
Problem solving.

Indicates that the associated text deals with problem-solving issues. Comments associated with
this icon attempt to generalize highlighted material in the adjacent text.
Common errors.
Indicates that the associated text deals with common errors.
Hyperlink target.
Indicates the target end of a hyperlink.
Program efficiency.
Indicates that the associated text refers to program-efficiency issues.
Student Resources
At the textbook website, http://www.mhhe.com/dean3e, students (and also teachers) can view and down-
load these resources:
∙ Links to compiler software—for Oracle’s JDK, Helios’s TextPad, Eclipse, NetBeans, and BlueJ
∙ TextPad tutorial
∙ Eclipse tutorials
∙ Student-version Microsoft PowerPoint lecture slides without hidden notes
The student-version slides are identical to the teacher-version slides except that the hidden notes,
hidden slides, and quizzes are omitted.
Omitting the hidden notes forces the students to go to lecture to hear the sage on the stage fill in the
blanks.
∙ GridWorld code
∙ Project assignments
∙ All textbook example programs and associated resource files
∙ Supplemental chapters
∙ Supplemental appendices
Instructor Resources
At the textbook website, http://www.mhhe.com/dean3e, instructors can view and download these resources:
∙ Teacher-version PowerPoint lecture slides with hidden notes
Hidden notes provide comments that supplement the displayed text in the lecture slides.
For example, if the displayed text asks a question, the hidden notes provide the answer.
dea75768_fm_i-xxxviii.indd 22 4/30/20 11:55 AM
Preface xxiii
∙ Exercise solutions
∙ Project solutions
∙ Test bank materials
Acknowledgments
The inspiration for this book is teaching, without which there would be no book. So thanks to the students
who have used prior editions of the textbook and provided valuable feedback. What helps them to learn is
what drives improvements in the book. And also a big thanks to the teachers who have used the book. With
their diverse views from diverse backgrounds, we’re able to glean important insights that can help make
the book approachable to a wider audience.
Anyone who has written a textbook can attest to what a large and well-orchestrated team effort it
requires. Such a book can never be the work of only one person, or even a few people. We are deeply
indebted to the team at McGraw-Hill Higher Education who have shown continued faith in our writing and
invested generously in it.
It has been a pleasure to work with Product Developer Heather Ervolino, who has overseen this third
edition’s development process. Helping us through the various stages of this edition’s production was
Project Manager Jason Stauter. We would also like to thank Senior Marketing Manager Shannon
O’Donnell, who helped in the final stages.
All the professionals we have encountered throughout the McGraw-Hill organization have been won-
derful to work with, and we sincerely appreciate their efforts.
We would like to acknowledge with appreciation the numerous and valuable comments, suggestions,
and constructive criticisms, and praise from the many instructors who have reviewed this edition and prior
editions of the book. In particular,
Christopher Crick, Oklahoma State University
Christopher Taylor, Milwaukee School of Engineering
Chris Johnson, University of Wisconsin, Eau Claire
Dennis Lang, Kansas State University
Daniel Leyzberg, Princeton University
Geoffrey Decker, Northern Illinois University
Jeffrey A. Meunier, University of Connecticut
Mark Pauley, University of Nebraska at Omaha
Patricia Roth Pierce, Southern Polytechnic State University
We would like to thank Park University colleagues Guillermo Tonsmann and Ken Dewey for their ongoing
support. They are dedicated to providing a solid foundation to their students in terms of problem solving,
object-oriented programming, and Java fundamentals, and it shows.
Thanks to the students who provided feedback and searched diligently for mistakes in order to earn
bonus points on their homework. In particular, thank you to Shyan Locke, Michael Dake, Marcus Shivers,
Olivia Leung, Manish Lamsal, Pranoj Thapa, Peter Boyle, and Jake Thomas.
Sincerely,
John and Ray
dea75768_fm_i-xxxviii.indd 23 4/30/20 11:55 AM
xxiv
One of the special features of this text is the diversity of its projects. Project subject matter spans six broad
academic areas, as this short table shows:
Abbreviation Description Easy Moderate Difficult Total
CS computer science and numerical methods 15 14 6 35
Business business and accounting 11 13 3 27
Sociology social sciences and statistics 6 8 5 19
Math  Phys math and physics 11 6 3 20
Engineering engineering and architecture 3 8 6 17
Biol  Ecol biology and ecology 0 3 4 7
		 Totals 46 52 27 125
The abbreviation in the first column above will be used in a larger table below as a brief identification
of a particular academic area. The four right-side columns in the above table indicate the number of proj-
ects in various categories. Of course, the highest number of projects (35) occurs in the area of computer
science and numerical methods. The 29 easy and moderate CS projects are typical CS introductory pro-
gramming problems. The 6 difficult CS projects provide gentle introductions to some advanced topics like
linked list operations, database operations, and simulated annealing.
In addition, there are 27 projects in business and accounting, which include miscellaneous financial
calculations, simple bookkeeping problems, and cost-accounting applications. There are 19 projects in social
sciences and statistics, which include applications in sociology and political science, as well as general expe-
rience. There are 20 projects in math and physics, which include applications in both classical and chaotic
mechanics. There are 17 projects in engineering and architecture, which include applications in heating
ventilating and air conditioning (HVAC), electrical engineering, and civil engineering. Finally, there are 7
projects in biology and ecology, which include realistic growth and predator-prey simulations. Although
we’ve associated each project with one primary academic area, many of these projects can fit into other
academic areas as well.
Because many of these projects apply to disciplines outside the field of computer science, we do not
expect that the average reader will already know about all of these “other” topics. Therefore, in our prob-
lem statements, we usually take considerable time to explain the topic as well as the problem. And we
often explain how to go about solving the problem—in layman’s terms. Therefore, working many of these
projects will be like implementing computer solutions for customers who are not programmers themselves
but understand their subject matter and know what they want you (the programmer) to do for them. They
will explain their problem and how to go about solving it. But then they will expect you to create the pro-
gram that actually solves that problem.
Because our project explanations frequently take considerable printed space, instead of putting them
in the book itself, we put them on our website:
http://www.mhhe.com/dean3e
The following table provides a summary of the projects on the book’s website. This table lists all of the
book’s projects in a sequence that matches the book’s sequence. The first column identifies the first point
Project Summary
dea75768_fm_i-xxxviii.indd 24 4/30/20 11:55 AM
Project Summary xxv
at which you should be able to do the project, by chapter and section, in the form: ChapterNumber.Section-
Number. The second column is a unique project number for the chapter in question. The third column
identifies the project’s primary academic area with an abbreviation that’s explained in the shorter table
above. The fourth column indicates the difficulty relative to where you are in your study of Java. For
example, what we call “easy” involves progressively more pages of code as you progress through the book.
The last two columns provide a title and brief description of each project.
Project Summary
Ch./Sec Proj.
Academic
Area Difficulty Title Brief Description
2.7 1 Business Easy Annual Bonus–
(Flowchart)
Draw a flowchart for an algorithm
that computes an annual bonus.
2.7 2 Business Easy Annual Bonus—
(Pseudocode)
Write pseudocode for an algorithm
that computes an annual bonus.
2.7 3 Business Easy Number of Stamps—
(Flowchart)
Draw a flowchart for an algorithm
that calculates the number of stamps
needed for an envelope. Use one
stamp for every five sheets of paper.
2.7 4 Business Easy Number of Stamps—
(Pseudocode)
Write pseudocode for an algorithm
that calculates the number of stamps
needed for an envelope. Use one
stamp for every five sheets of paper.
2.7 5 Biol  Ecol Moderate Five Kingdoms—
(Pseudocode)
Write pseudocode for an algorithm
that identifies a biological kingdom
from a set of characteristics.
2.7 6 Math 
Phys
Easy Speed of Sound—
(Flowchart)
Draw a flowchart for an algorithm
that provides the speed of sound in a
particular medium.
2.7 7 Math 
Phys
Easy Speed of Sound—
(Pseudocode)
Write pseudocode for an algorithm
that provides the speed of sound in a
particular medium.
2.7 8 Business Moderate Stock Market
Return—
(Flowchart)
Draw a flowchart for an algorithm
that prints the type of market and its
probability given a particular rate of
return.
2.7 9 Business Moderate Stock Market
Return—
(Pseudocode)
Write pseudocode for an algorithm
that prints the type of market and its
probability given a particular rate of
return.
2.8 10 Business Moderate Bank Balance—
(Pseudocode)
Write pseudocode for an algorithm
that determines the number of years
until a growing bank balance reaches
a million dollars.
(continued)
dea75768_fm_i-xxxviii.indd 25 4/30/20 11:55 AM
Discovering Diverse Content Through
Random Scribd Documents
great sphere of activity, next to the wide field of literature, was the
more modest compass of the eighteenth century salon.
Madame de Lambert herself draws a parallel somewhere between
the salons of the seventeenth and those of the eighteenth century,
more especially with regard to the prevailing codes of morality. Her
conclusions, like those of M. Brunetière nearly two centuries later,
are overwhelmingly in favour of Mme de Rambouillet and her
contemporaries. She complains that the delicate intellectual
amusements of the seventeenth century assemblies have been
largely superseded by the grosser delights of the card-table and of a
declining stage. The merest semblance of knowledge is regarded
with disapproval,—this in consequence of Molière's furious onslaught
in his Femmes Savantes—and as a natural consequence of
ignorance, the female morals have sadly decayed. Being thus
deprived of the means of improving the mind, women are naturally
driven to a life of pleasure-seeking. And she doubts whether society
has derived any benefit from the change. Les femmes ont mis la
débauche à la place du savoir, le précieux qu'on leur a tant reproché,
elles l'ont changé en indécence. In other words, Mme de Lambert
wanted to return to the earlier preciosity, granting women the right
to be instructed, and trying to steer clear of those excesses which
had called forth the attacks of Molière and Boileau. She emphatically
protests against the pernicious habit of making a pleasing
appearance the sole aim of female education, and claims for her sex
the blessings of an education which in cultivating the mind will
improve the female morals.
It would be impossible to deny that the moral standard was
considerably lower than it had been half a century earlier. The
consequences entailed by the revocation of the Edict of Nantes and
by the suppression of Port Royal had been equally disastrous. The
chief bulwarks of Protestant and Catholic orthodox faith had been
removed, leaving a free field to both libertinage and disbelief. The
coarseness of manners which it had been the aim of the Rambouillet
societies to suppress reasserted itself on the one hand, while on the
other the rising spirit of philosophical inquiry and scientific research
had degenerated into a scepticism which was no longer counteracted
by that spirit of religious mysticism which had been a weapon of
orthodoxy against unbelief. The Encyclopedian spirit often spelt
deism and atheism, both of which flourished in the salons. The very
fact that their society was no longer exclusive, but freely admitted
people of all class and opinions, and from different parts of the
world, accounts for the enormous influence exercised by these
bureaux d'esprit upon public opinion in the eighteenth century.
Moreover, the monarchical power was declining, and the king, in
establishing a barrier between himself and the society of the salons,
was himself instrumental in raising opinions which more and more
became the prevailing ones, and upon which he had no influence
whatever. Rationalism began to gain ground rapidly and became a
basis for speculations which soon came to include politics and
economics.
M. Brunetière, whose judgment on the salons of the eighteenth
century is very severe, complains that the lofty artistic and moral
ideals of the preceding generation had given way to scepticism and
to cynicism of a kind which made Madame de Tencin refer to her
guests as ses bêtes. This statement, which no doubt is mainly
correct, seems strange in consideration of the fact that it was by the
new philosophy which the same salons helped in spreading, that the
great problems of the future of the human race were put forward,
which in broader minds gave rise to much idealism in what M. du
Bled so finely calls: le souci de la modernité. But eighteenth
century society regarded philosophy as an intellectual pastime rather
than as bringing the hope of relief to the oppressed millions, and if it
occasionally dabbled in social problems, the misery of the multitude
did not touch the majority of those who lived lives of comfort and
luxury, and were utterly unacquainted with suffering, very deeply. No
direct attempt at improvement, therefore, was to be expected from
them, they were talking in theory about things of the practice of
which they knew nothing. Brunetière calls the eighteenth century
salon le triomphe de l'universelle incompétence, with which its
seventeenth century predecessor, with its more limited programme,
compares favourably. It became habitual to talk wittily of serious
problems, while seriously discussing trifling subjects. It needed,
indeed, the fiery imagination and fervent enthusiasm of a Rousseau
to inspire the philosophical theories with the life of his genius. And
yet, if the social problems of the time were not directly solved by
eighteenth century society, they were at least formulated by it in
such a manner as to make them the catchword of the period and to
draw to them the attention of those who were better able to do
them justice. The very fact that the salons were ruled over by
women and independent of court-influence made them the place
where opinions were most freely uttered and most readily listened
to.
Literature, which had been the chief occupation of the early salons,
now found a powerful rival in science. The poetry of the eighteenth
century ruelles became of an even lighter and more insipid kind.
On the other hand, the latter half of the previous century had
witnessed a growing interest in anatomy and surgery, and after the
introduction (by Fontenelle) of astronomy as a fashionable science,
Newton became the rage, and ladies of quality like the marquise du
Châtelet were among his worshippers. The domination of the salons
thus became extended to philosophy, science, economics and
politics. When the Ancient and Modern controversy was re-
introduced in the opening years of the century, nearly all the female
philosophers were fervent partisans of the Moderns, believing in a
future in which all human beings would be guided by the light of
Reason.
Of this eighteenth century modernism, feminism is, in fact, only a
subdivision. This appears from the work of Poullain de la Barre, and
still more from the great defence of the Cause of Woman (when
threatened by Boileau in Satire X Sur les Femmes) by the great
champion of modernism Perrault in his Apologie des Femmes. The
Moderns, indeed, saw in the prejudice against women a remnant of
the servility of antiquity which was in flagrant contradiction with the
dictates of Reason. Hence the close connection between feminist
literature in the eighteenth century and life in the salons, of which
the authors were mostly among the regular frequenters. The
marquise de Lambert laid down her ideas of feminism in her
Réflexions sur les Femmes, and we have seen that both
D'Alembert and Marivaux were among the staunch defenders of the
right of the sex to equal consideration.
Boileau's death had left the précieuses in the undisputed
possession of the field of light literature, to which now became
added that of science. This new form of preciosity, la préciosité
scientifique, which made its appearance in the salon of Mme de
Lambert, where it found an ardent worshipper in Fontenelle, grew so
powerful that even Voltaire's efforts to crush it with ridicule were
unavailing. So strong had the female dictatorship become, that three
of the most influential men-of-letters in the kingdom had vainly tried
to get the better of it. But unfortunately the platonic ideal to which
the women of the preceding century had owed their ascendancy had
degenerated, and in consequence of the altered circumstances
women often had to buy with physical submission and degradation
that worship of their beauty and deference to their opinion which
made them at the same time the rulers and the slaves of men, and
against which the moralists of the century, with the glaring exception
of Rousseau, made it their business to protest loudly, but in vain.
Mme de Lambert merely wanted to restore the right sort of
preciosity to its throne as an antidote to the evils of ignorance, in
which she set herself the ideals of the Hôtel de Rambouillet, and
advocated moderation in everything. Her salon thus became as
much a protest against exaggeration and affectation as against the
prevailing opinion that the education of women should only aim at
teaching them how to please the opposite sex. An occasional
frequenter calls it l'hôtel de Rambouillet présidé par Fontenelle, et
où les précieuses corrigées se souvenaient de Molière.
Being left a widow at a comparatively early age, Mme de Lambert
opened her salon in the Palais Mazarin in the rue Colbert about
1700. She was at that time rather more than fifty, and reigned
supreme over her circle of visitors for more than thirty years. She set
herself to prove that it was possible to have a lively entertainment
without the help of the card-table, relying chiefly on conversation
and literature. Her Tuesdays and Wednesdays soon became famous,
and attracted both the aristocracy and the literati. Among her
regular visitors were Fontenelle, Marivaux, Mlle de Launay (Mme de
Staal) and de la Motte, champion of the moderns, whilst Mme Dacier
undertook the defence of the opposite cause. Mme de Lambert
herself was the ruling spirit of the Académie, of which the way
towards membership lay through her favour, and the chief literary
productions previous to being published—if published they were—
were read and criticised in her circle.
If Mme de Lambert deserves mention for having kept a salon which
formed a link between the seventeenth and the eighteenth century,
and exercised a beneficial influence on the tone of conversation, she
is even more entitled to attention on account of the part played by
her in the development of feminism. She was a moralist rather than
educator, and followed in the steps of Fénelon. She had the
Cartesian belief in the infallibility of Reason, with two exceptions,
which do honour to the qualities of her heart, and saved her from
the inevitable conclusions of logic à outrance: religion and honour. Il
y a deux préjugés auxquels il faut obéir: la religion et l'honneur,
and a little further: En fait de religion, il faut céder aux autorités.
Sur tout autre sujet, il ne faut recevoir que celle de la raison et de
l'évidence, excluding even honour. But her actions show that she
realised the danger which lies in obeying the duties of reason while
totally excluding the admonitions of the heart. Stronger than her
love of logic was that exquisite form of sensibility which made her at
least a real champion of the less fortunately situated. There is real
concern for the welfare of her inferiors in the precept that servants
should be treated as unhappy friends, and a true love of humanity
in the statement that humanity suffers in consequence of the
inequality which Fortune has introduced among men. Words which
come from the heart and entitle her to sympathy and admiration.
Her ideas concerning female education are contained in the Avis
d'une mère à sa fille. She insists on the importance of cultivating
the female mind to render woman an agreeable companion to her
husband, who will then honour her and give her her due. And she
places herself on the standpoint which Mary Wollstonecraft took
after her, in basing upon this foundation her vindication of women's
right to be instructed. She complains of the tyranny of men, who
condemn to ignorance the partners of their wedded lives,
disregarding the pernicious consequences entailed thereby. For
ignorance leads to vice, and the mind should be kept employed,
were it only as a means of avoiding mischief. To Mme de Lambert
the Muses were l'asyle des moeurs. Her educational scheme
contains more instruction than Fénelon's, as it includes philosophy,
which is to reclaim women to virtue through the medium of Reason.
Of all the French female authors on the Woman Question it is Mme
de Lambert whose ideas show the nearest approach to Mary
Wollstonecraft. The essential difference between the two—the
former's indifference to political emancipation—was due to a
difference in social circumstances, which made her a ruler whose
influence over men no political enfranchisement could have
increased, and also to the condition of things in France, where the
first steps towards the political equality of the stronger sex were yet
to be taken. She believed the domestic circle to be the proper
sphere of women, and her metaphysics of love—if less fantastic
than the ideals of her 17th century predecessors, which, however,
found some adherents among the regulars of her own circle in de la
Motte and the Duchesse du Maine—were certainly more conducive
to real happiness in the high moral principles out of which they
arose. It was the marquis d'Argenson who said of her writings that
they were un résumé complet de la morale du monde et du temps
présent la plus parfaite, and there seems no reason to doubt the
truth of his judgment.
Unfortunately the good example set by the marquise de Lambert
was not followed in other circles, where the increasing influence of
the feminine element, instead of purifying the morals of the male
sex, depraved them yet further. The great catastrophe of the end of
the century was hastened by the vicious excesses of many females.
Goncourt says that the eighteenth century lady of quality
represented the principle that governed society, the reason which
directed it and the voice which commanded it; she was, in fact, la
cause universelle et fatale, l'origine des événements, la source des
choses, and nothing could be achieved without her concurrence.
Rousseau, when first arriving in Paris, was advised by a Jesuit to
cultivate the acquaintance of women, for nothing ever happened in
Paris except through them.
The bulk of female influence upon the morals of the century was
disastrous. The gross materialism amongst society-women found
expression in a well-known utterance of the marquise du Châtelet:
We are here merely to procure ourselves the greatest possible
variety of agreeable sensations. The most perverse code of morality
came to reign in some of the most-frequented salons. One of the
leading hostesses of Paris boasted that one of her reception-days
was reserved for gentlemen of a damaged reputation, the so-
called jour des coquins. Of the Englishmen who frequented these
circles of appalling vice, Horace Walpole—who in a space of forty
years paid six successive visits to Paris, and who was very far indeed
from being a sentimentalist,—refers to the utter absence of any
sense of decency among people whose chief occupation was the
demolition of all authority, whether temporal or spiritual, including
the Divine Authority itself.
One of the worst examples of the epicurian spirit was furnished by
the salon of the notorious Mme de Tencin. She disdained even to
keep up the appearance of quasi-platonic courtship and lived in open
and shameless debauch. Her entire life was made up of political
intrigues and adventures of gallantry, in which she turned the latter
to account to promote the former. She possessed plenty of literary
talent, and her two novels Le Comte de Comminges and Le siège
de Calais rank among the best female productions of the century—
but even Fontenelle thought her heartless. After a childhood spent in
the very imperfect seclusion of a convent which was notorious for its
nocturnal orgies, la religieuse Tencin came to Paris in 1712 to
begin her siege of male hearts, directing her first attack against no
less a person than the Regent himself, and ultimately contenting
herself with one of his ministers, which gallant adventure was
followed by many more. She gave birth to a child, whom she
deposited on the steps of a church, to be found and brought up by
strangers. This child afterwards became the famous d'Alembert.
In order to be able to pursue her political schemes she filled her
salon on different days of the week with people of various
occupations and interests; keeping philosophers and académiciens,
politicians and ecclesiastics carefully separated, making herself their
confidante, and possessing herself of their secrets, managing them
all so cleverly that they became her tools without being aware of it,
secretly despising her bêtes while openly flattering them. The
visitors to her two weekly dinners were nearly all men, Bolingbroke
and Matthew Prior being among her habitués. Apart from Mme
Geoffrin, who became her successor, and of whom she said that she
only came to see if there was anything among her inventory that she
might have a use for, there were hardly any women, for Mme de
Tencin would brook no possible rivals. Such was her degradation that
she wrote a most indecent Chronique scandaleuse for the special
delectation of the Regent. As Mme de Lambert's salon represents
eighteenth century society at its best, so Mme de Tencin's
foreshadowed some of the worst instances of female intriguing that
were to follow.
A totally different salon was that kept by Mme Geoffrin. Mme de
Tencin—whose own birth was not above suspicion—had all the pride
of class, and looked down upon the Third Estate; Mme Geoffrin on
the contrary was the daughter of a court-valet and consequently
remained all her life a bourgeoise, without any pretence to
préciosité or anything but a kind and warm heart, a most
remarkable wit, sound common sense and a natural delicacy which
made her an ideal hostess. For Mme de Tencin's lofty disdain she
substituted an almost maternal solicitude for the welfare of her
children, who, with the exception of Mlle de Lespinasse, were of
the male sex. Besides d'Alembert, Diderot, Morellet and Grimm there
were the ubiquitous Horace Walpole, David Hume the philosopher
and Wraxall; the first-named of whom in his correspondence
declared her to be a most extraordinary woman with more common
sense than he had ever encountered in one of her sex.
The principles of the salon in the Rue St. Honoré were much the
same as at Mme de Tencin's, but a milder spirit prevailed, and the
demon of intrigue was absent. Mme Geoffrin kept fixed reception-
days, her Mondays being devoted to artists, and her Wednesdays to
men-of-letters and philosophers, while her intimates were made
welcome on both days. The hostess presided over the assemblies
without in any way obtruding her personal opinions or bringing her
private interests into play, exercising an absolute authority which
never became tyranny, and keeping peace among the more excitable
of her guests[12]. She was much appreciated by them all, not least
by the future king of Poland, Stanislas Augustus, her devoted son,
causing Walpole to refer to her as the queen-mother of Poland.
Her apotheosis came when in her sixty-eighth year she visited
Warsaw, where she met with a royal reception. After her return her
mental powers declined rapidly, and her daughter—fearing the
influence of scepticism upon her mother—kept her favourite
philosophers at a distance, eliciting from her the remark that she
was, like Godfrey of Bouillon, protecting her tomb against the
infidels.
The third of the Muses of the philosophical Decameron, whose
salon was much in vogue, was Julie de Lespinasse, whose attractive
personality and brilliant conversational and epistolary powers
account for her success. She combined the warmth of heart of Mme
Geoffrin with the ardent temperament of Mme de Tencin, but
without the latter's brazen-facedness. She possessed a degree of
sensibility which made her succumb to different lovers for each of
whom she cherished a passion which it was beyond her power to
resist. Her youth had been fed with Richardson, Clarissa Harlowe
being her favourite. She had entered the employ of the famous
marquise du Deffand, herself a prominent hostess, in the capacity of
reader. Her wit and the natural buoyancy of her character soon
made her more popular than her mistress, whose guests took to
visiting her in her room, while her mistress was still asleep. Mme du
Deffand in her jealousy accused her of skimming off the cream of
her visitors' conversation; a breach followed, and Julie was enabled
by some supporters to set up a small salon in the rue St. Dominique,
which flourished from 1764 till the year of her death in 1776. She
could not afford sumptuous dinners, but her guests were sure of a
warm welcome and of some interesting conversation, which she
conducted so tactfully, effacing herself completely and making her
guests feel at home by always appearing interested, that her lack of
personal beauty was quite forgotten in the charm of her manner.
Politics were a frequent topic, and Mlle de Lespinasse was among
the professed admirers of the British Constitution. D'Alembert,
Condorcet, Turgot and also Mme Geoffrin belonged to her circle, and
that Walpole knew her also, appears from the correspondence
between him and Mme du Deffand, who at Julie's death complained
that the rupture with her had robbed her of the friendship of
d'Alembert.
While the women of society were celebrating their triumphs in the
salons, philosophy was trying to do something for the female
multitude. We have seen that it was Fénelon who caused education
to be included among the subjects of moral philosophy, but it was
the diffusive power of Rousseau's writings that made it one of the
most frequently discussed themes of the century. His Emile, ou de
l'Education, which appeared in 1762—curiously enough, the year of
the suppression of Jesuitism in France—marked a new era in the
history of education, if not in that of feminism. Of Rousseau it might
have been reasonably expected as the champion of liberty and
equality to carry to their full extent the philosophical venturings of
Fénelon and thus to usher in a new era of female emancipation.
However, with an inconsistency which is one of his chief
characteristics, Rousseau not only deliberately left the female half of
mankind out of his scheme for political enfranchisement, but ranged
himself among the anti-feminists by the great emphasis he laid on
the consideration of a sexual character, which he construed into
evidence of female inferiority, by arguing that it makes the
subjection of woman a natural law, which is to be respected
according to the theory that whatever is in Nature, must be right.
Owing to the contradictory nature of his views, however, while
directly opposing the movement, he indirectly furthered it in two
ways. In the first place, his social theories were adopted without
reserve and without restrictions by some of his followers, who thus
repaired the omission which had left Woman out of the scheme; and
secondly it was Rousseau who once for all broke the back of the
monastic system of education by continuing the campaign which
Fénelon in theory, and Mme de Maintenon in practice, had entered
upon before him, and bringing it to a happy conclusion. The
reduction and ultimate abolition of the education of religion, which
was one of the great victories of the philosophical school, became
manifest in the latter half of the century. It was a signal success,
achieved over an unwilling government and crowned by the
expulsion of the Jesuits, who had formed one of the chief bulwarks
against the growing revolutionary spirit.
The Cartesian principles, which had been a beacon-light to
seventeenth century philosophy, were supplemented in the next by a
new element: that of utility. In John Locke's Treatises of
Government and also in Some Thoughts concerning Education, he
let himself be guided chiefly by considerations of usefulness, thus
becoming the founder of that doctrine of Utilitarianism which, after
influencing the French Encyclopedians, was to return to England a
century later and to find a fervent champion in William Godwin. In
deciding upon a course of action, the inevitable question was: What
is the use? and this guiding principle became paramount also in
matters of education. To Locke, who was a man of practical sense
and not a mere theorist, the problem was how to make people
understand their real interests, and to make them act in accordance
with them, which must necessarily lead to happiness. His
educational system, therefore, is based upon the communication of
such useful knowledge as will most contribute to the total amount of
happiness to be found on this globe[13]. Locke insisted on the
necessity for a physical education which increases the mental and
moral capacity by rendering the body less subject to fatigue.
Simplicity and effectiveness in dress and food, and plenty of outdoor
exercise are recommended, and in this important matter, as indeed
in a great many others, Locke may be said to have struck the
keynote of the philosophical tendencies of the eighteenth century,
anticipating the famous Nature-theory of Rousseau. Many important
questions were mooted by him. He introduced the ethical problem of
reward and punishment, and discussed the advisability of reasoning
with a child and of making him learn a trade, which became a part
of the educational programme of the next generations.
The French philosophers became Locke's immediate heirs, and
afterwards repaid their debt to England with interest. Where Locke
gave his young gentleman a tutor, his views were adopted by the
opponents of the monastic education. It could hardly be expected of
Locke, who lived in a time when the female fortunes in his own
country were at a very low ebb, to have paid much attention to the
possibility of making women share in the obvious advantages of the
new system. However, if he did little or nothing for British women,
his theories were turned to account for the benefit of their French
sisters, whose position in the lower walks of life was not very much
better than theirs. His French disciples, carrying the theory of utility
to its fullest extent, included the female sex in their reflections. The
first in point of time was the Abbé de St. Pierre, of whom Rousseau
contemptuously said that he was a man of great schemes and
narrow views. Seen from a feminist standpoint this judgment is
cruelly unjust. For, even granting that the Abbé's schemes were too
Utopian to be capable of full realisation—a circumstance he himself
sadly recognised—the fact remains that he was responsible for the
first project of female education on a national basis, making
wholesale education a state-concern and thus wanting to extend the
benefit of instruction to many who would otherwise be deprived of
it. He stands at the beginning of the lane that leads via Bernardin de
St. Pierre and Talleyrand to the great Condorcet.
The Abbé de St. Pierre was willing to grant women as a class that
equality which the better-class women had actually attained, and he
believed in their instruction, holding that on the instruction given to
the young, whether male or female, depended the happiness of the
coming race. But he believed still more in the necessity for a moral
education, for his utilitarianism is not of this earth, but of eternity.
With him the ever recurring question is: What will it profit the
soul?, and the fear of punishment in Hell is rather stronger with him
than the sense of moral duty. He thus laid himself open to attack
from the notorious Mme de Puysieux, who believed in reputation and
the preservation of appearances, informing him that it was silly to let
the fear of Hell withhold people from seeking happiness by
cultivating the good opinion of others, whether deserved or not! The
final clause sums up what moralists found most objectionable in the
inclinations of a depraved age.
The real aim of women, according to the Abbé, should be to please
God, and not men, so as to gain eternal life. He has no ambition for
women beyond that of making them devout Christians and good
housekeepers, and his educational efforts are accordingly directed
towards these two accomplishments. Girls are to dress simply, to
eschew cards—that curse of the age—and to learn useful
needlework, the keeping of accounts and in general such things as
will be of the greatest use to them in the performance of their
domestic duties. But he very unaccountably refuses their youth the
advantages and innocent enjoyments of home-life, wishing them to
be brought up in colleges, in which they are to be kept immured
until such time as their education will be completed, when they will
be ready for matrimony! At college girls may learn to be good
citizenesses, but they will scarcely gain the necessary experience for
managing a home of their own. The comprehensiveness of his
scheme, however, and his recognition of the female equality entitles
him to a place in the history of feminism above Rousseau.
The latter's attitude towards the feminist movement is so
complicated as to demand careful analysis. Where women were
concerned the strong individuality of the female genius would not
allow him to side fully either with those who wished to condemn
them to a life of household-drudgery, making of them a sort of
superior slaves, or those who, not satisfied to vindicate woman's
rights, made her usurp those of the stronger sex, for the former
have too low a notion of the duties of womanhood, whilst the latter
overlook the considerations of a sexual character by which,
according to Rousseau, the relations between the sexes are
exclusively determined. Rousseau's opinion of the depth to which
women had sunk appears from his Lettre à d'Alembert sur les
Spectacles, which contains a fierce onslaught upon their moral
perversity, which has caused the drama, too feeble to rise to
worthier themes, to fall back upon erotics of a most despicable kind.
Rousseau judged women capable of becoming something better
than what eighteenth century society had made of them, but in his
demands for them and in his schemes for perfecting their moral
education he was extremely modest. Next to the salons he held the
education of the convents, ces véritables écoles de coquetterie, to
be chiefly responsible for the degradation of the female character.
The young women who, on leaving them, enter society, carry into
instant practice the lessons of vanity and coquetry which the
convents have supplied. For convent and salon Rousseau wanted to
substitute the blessings of true domesticity—painted in glowing
colours in the pages of the Nouvelle Héloise. His sympathies went
out, not to that college-life of which the Abbé de St. Pierre had such
sanguine expectations, but to the intimacies of the family-circle,
presided over by loving parents, an ideal which he reintroduced in
the fifth book of his treatise on education, where, circumstances
rendering it advisable to provide the finished male product with a
suitable partner for life, the principles of Sophie's education are
elaborately described[14].
Where he recommends making the duties of life as pleasant as
possible to the young pupil, protesting against that austere
conception which allowed her no other diversion than studies and
prayers, Rousseau sides with Fénelon. In his opinion girls enjoy too
little freedom, whilst grown-up women are left too much liberty. Let
the young girls have an opportunity to enjoy life, he says, or they
will take it when they are older. Nor does the notion of making them
at an early age acquainted with the world inspire him with terror, for
he trusts with Mme de Sévigné that the sight of noisy gatherings will
only fill them with disgust instead of tempting them to imitation.
So far there is nothing anti-feminist in Rousseau's ideas. But
unfortunately we have come to the end of what is positive and his
further utterances rather advocate woman's subjection than her
enfranchisement. The habit of reverting to first principles which is so
dominant a characteristic of his Nature-theory makes him draw a
parallel between the sexes upon the foundation of those innate
qualities which constitute the sexual character. Men and women are
the same in whatever is independent of sex, and radically different,
almost diametrically opposed, in all that pertains to it. Thus all
disputes regarding equality are vain, for in what the sexes have in
common they are naturally equal, and in that in which they differ no
comparison is possible. And woman is to be congratulated upon this
diversity, for in it lies the great secret of her subtle power. Where
woman asserts the natural rights which arise from this difference she
is superior to man; where she tries to usurp the natural rights of the
opposite sex she remains hopelessly below their level. The two sexes
have different spheres of activity, and each sex can do well only in
its own sharply-defined sphere.
Reason itself demands this stress laid on the contrast between the
sexes. For, says Rousseau, once women are brought up to be as like
men as possible, their authority and influence, which are rooted in
their being essentially different, will be lost without a substitute. This
remark is one of great wisdom and psychological insight. Rousseau
saw what many extreme feminists are so apt to forget, that those
who wish to develop in women those qualities which naturally
belong to man, and to suppress in them what is proper to their own
sex, are in reality doing them irreparable harm.
There are, according to Rousseau, a male empire and a female one.
The former rests upon a foundation of superior physical strength and
mental superiority; but although the stronger sex are masters in
appearance, they in reality depend on the weaker. For the female
empire, established by Nature herself, derives its strength from
those delicate feminine charms which command the worship of that
gallantry which Nature again has instilled into the hearts of men.
In giving this interpretation of female power and influence Rousseau
exposed himself to attack. The platonic worship, we have seen, had
sadly degenerated, and what remained was a worthless, hypocritical
imitation which was felt by well-meaning women as an insult rather
than a compliment. But what called down a storm of feminist
indignation upon his head was the sweeping conclusion he drew
from the natural law that man, having physical strength on his side,
must always play the active part in the intercourse between people
of different sexes, while woman has to be always content with the
passive rôle. The sole object of women, says Rousseau, ought
consequently to be to please men, on whom their relative weakness
has made them dependent, and goes on to assert that all female
education should as a natural consequence be relative to men.
There is in the above passage, which shows that on the subject of
feminism Rousseau, instead of a revolutionary, was rather a
conservative, nothing to suggest the bold and daring vindication of
female rights that was so soon to resound in the philosophical world
like a mighty trumpet-blast. His ideas about the position of Woman
are characteristic of his want of equilibrium in presenting a
bewildering chaos of judicious observations and unaccountable
oversights. It is not so much that some of his statements are untrue,
as that they are incomplete. In drawing sweeping conclusions from
the physical inferiority of the sex he deliberately closes his eyes to
their moral and mental possibilities. It is true that he insists upon a
moral education for women, but whatever of merit may be contained
in this claim is instantly neutralised by its only object: making
women more acceptable companions to their husbands, contributing
to the happiness of the latter by unwearying devotion and
unalterable constancy. There are undoubtedly many women to
whom the above would seem the most acceptable task, as there are
others whose consciousness of their talents would make them
indignantly reject so subordinate a part. As long as women are not
cut after the same pattern, allowance will have to be made for
individual propensities and any theory, however cleverly put
together, will succeed with some types of womanhood and
hopelessly fail with others.
St. Marc Girardin indignantly remarks that the condition of the
women in Rousseau's Nature-scheme suggests the oriental seraglio.
This is an exaggeration, for the relative education is qualified by
Rousseau to such an extent that the harem-picture which it may at
first conjure up is considerably modified. He wished the term made
to please men to be understood in a far wider meaning than the
merely sensual, for no one realised better than he that in the
absence of a spiritual element no love based upon the grosser
passions can possibly endure.
Where the female weaknesses and vanities are concerned
Rousseau's discernment even surpasses that of Fénelon. The task of
woman being to please, Nature has made her regard above all
things the opinion of the opposite sex. And the moralist who teaches
men to ignore the opinion of others as destructive of individuality,
goes so far as to prescribe for women an unlimited deference to
opinion and reputation. Opinion, which is the grave of virtue among
men, ought to be among women its high throne. The utilitarian
question: A quoi cela est-il bon?, which is to be the guiding
principle in Emile's case, changes its character where Sophie is
concerned, and becomes: Quel effet cela fera-t-il? The question
what impression a thing will produce naturally leads to putting the
shadow before the substance, and appearance before reality, and as
such may have a most disastrous effect.
Sophie's love of needlework is accounted for not so much by
considerations of usefulness as by the reflection that this delicate
occupation will make her appear to advantage to her admirer. The
same train of thoughts makes her abominate the useful occupation
of cooking, by which her hands might become soiled. Did Rousseau
actually imagine that his much-recommended simplicity in dress
would hold out against the innate love of finery which was to help in
the accomplishment of what he considered the chief aim of
womanhood?
Rousseau certainly did not mean to imply that woman must of
necessity be morally inferior to man, but simply that Nature had
ordained that she shall be subjected to his superior strength, to his
cooler judgment and to his superior common sense. He was certainly
capable of imagining an ideal female, and of worshipping in her the
essentially sexual qualities which make her differ from man. That
portion of the fifth book of Emile which deals with the first meeting
between the lovers leaves little doubt as to how he pictured to
himself his ideal of womanhood. The philosophical treatise is more
than once in danger of becoming a romance, embodying the slightly
sobered ideals of courtship of the author of Julie. It cannot be
denied that Sophie has charm and that her subjection to Emile is not
oppressive. But to form a correct notion of Rousseau's ideas
regarding the social position of women we must strip the story of its
lyrical element and glance at the purely philosophical portion of the
treatise. It is there that we must look for an answer to the question:
Did Rousseau look upon women as partakers of the faculty of
Reason? And he gives his reply in the following words: L'art de
penser n'est pas étranger aux femmes, mais elles ne doivent faire
qu'effleurer les sciences de raisonnement. He would not even object
to a system by which the functions of women were strictly limited to
the performance of sexual duties, if it were not that utter ignorance
would make them fall a too easy prey to rascally adventurers! The
subsequent statement that, after all, it being the task of woman to
get herself esteemed, so as to justify her husband's choice, a little
knowledge would not come amiss, does not mend matters in its re-
introduction of the relativity-principle. Here indeed, Rousseau
pitches the pipe too low.
Woman's special domain is that of sentiment. But the very
sensibility which renders her more alluring by contrast, prevents
her from forming a sound judgment. This appreciation of women
appears clearly in the passages of Emile in which the choice of a
religion is discussed. Emile is not allowed to decide until he has
completed his eighteenth year, when he is made to judge for himself,
uninfluenced by his tutor. Sophie's religious notions, on the contrary,
are carefully instilled by her parents at an early age, it being silently
taken for granted that she will never arrive at a degree of
understanding which will enable her to form her own convictions.
The female reason is of a practical nature, which renders them very
quick to find the means of arriving at a fixed conclusion, but does
not enable them to form that conclusion independently of others.
Again that utter dependence, that total lack of individuality which
characterises Rousseau's female ideal. My daughter, says Sophie's
father, knowledge does not belong to your age; when the time has
come, your husband will instruct you.
The amount of actual instruction in Rousseau's scheme is reduced to
a minimum. There is no knowing what damage may be done to the
unstable female imagination by the dangerous literature of the time.
Here we recognise the author of the Dijon prize-essay with its
crushing conclusion. Rousseau frankly hated the femme bel esprit.
Sophie's mind is to be formed by observation and reflection, and not
by books. But how can Sophie be supposed to reflect, one might
ask, unless she had certain fundamental truths pointed out to her,
the instilment of which is not the work of every parent, however
well-intentioned? It is Rousseau's fatal mistake that he cannot bring
himself to realise that moral culture simply cannot exist without a
certain amount of intellectual culture. He wanted to have both
granted to men, and his conclusions tended to withhold both from
women. The march of humanity finds him in the first rank of those
who were pioneers; the feminist movement, while recognising his
cleverness, looks upon him as a dangerous, and sometimes does
him the injustice of calling him an hypocritical enemy.
The charge of insincerity has, indeed, been often brought against
him, although he has found some defenders also. However, he is
condemned by most women. Mrs. Fawcett, in her introduction to
Mary Wollstonecraft's Vindication, opines that a man who made so
light of his duties towards his own children, and whose married life
was so full of blame has no right to pronounce on problems which
require the disinterestedness and self-abnegation of the pure
idealist. Where Rousseau points out the shortcomings of the women,
of his time and regrets them, he is with Mary Wollstonecraft; where
he fails to show the way by which improvement may be attained, he
remains hopelessly behind one who, with considerably less genius,
had a great deal more moral courage and a far wider conception of
the ideals of woman.
Of the disciples and opponents of Rousseau, some of whom, like
Mme de Staël, Mme de Genlis, and Mme de Necker de Saussure
were of the female sex, little need be said here, as their writings
either did not throw any new light on the problem under
consideration, or belong to a period following that of Mary
Wollstonecraft. When the Revolution came, bringing with it an
increased demand for a public education, some of its theorists, who
like Condorcet, showed an interest in the female part of the
problem, will call for mention.
FOOTNOTES:
[10] The Revue d'Histoire Littéraire de la France (Tome XXIII, XXIV
and XXV) contains a contribution by M. Raymond Toinet entitled:
Les Ecrivains moralistes au 17ième siècle; being an alphabetical
nomenclature of moral writings published during the age of Louis the
Fourteenth (1638-1715). In this list works of a feminist or an anti-
feminist nature figure so largely that little doubt can be entertained
as to the interest taken in the topic under discussion. They may be
conveniently classified as follows:
1. Assertions of female superiority, including a. o. two French
translations of Agrippa, three pieces entitled: Le Triomphe des
Dames, and one by Mlle. Jacquette Guillaume, entitled: Les
Dames Illustres. They were frequently combined with attacks
on the male half of humanity, as in the case of Regnard's Satire
contre les Maris.
2. Apologies for the female sex, including Perrault's Apologie
des Femmes, Poullain de la Barre's Egalité des deux Sexes,
and a Latin translation of Anna Maria Schuurman. Some were
meant as a refutation of some male attack. To this class belong
Ninon de l'Enclos' Coquette Vengee and a number of replies to
Boileau's satire.
3. Attacks on the female sex, which are gradually diminishing in
number, or rather changing from the direct invective to the
moral essay with a didactic purpose, busying itself with the
female morals and the female character. A collection of pieces
dealing with the problem of sexual preference was published in
1698 by de Vertron under the name of La nouvelle Pandore, ou
les femmes illustres du siècle de Louis le Grand.
4. Rules of female conduct, for the use of young ladies about
to enter the world, insisting chiefly on the feminine duty of
preserving the reputation. A translation of Lord Halifax's
Advice (see page 83), Etrennes ou conseils d'un homme de
qualité à sa fille seems to have attracted some notice.
5. Pieces dealing with the relations between the sexes in daily
intercourse, including the subjects of love and gallantry, and of
marriage. Some are directly favourable to the state of
matrimony, pointing to the reciprocal duties of the partners in
the contract, and instructing them in the readiest way to
happiness; others, frequently deriving their inspiration from
Boileau, arguing about marriage as a social institution and
enumerating its advantages and its drawbacks. To the period
under discussion belongs a translation of Erasmus' Christian
Marriage.
6. Treatises of female education, containing a plea for the
development of the female intellect. They are, as yet,
remarkably few. Beyond the contributions by Poullain de la
Barre and Fénelon there are some half-dozen pieces dealing
with the education of girls on a religious basis, and a few in
which the question of the pursuit of science and philosophy by
women is stated and answered favourably. There was an
Apologie de la science des Dames, par Cléante, (1662); a
treatise entitled: Avantages que les femmes peuvent recevoir
de la philosophie et principalement de la morale, (1667);
another by René Bary bearing the somewhat questionable title
of La fine philosophie accommodée à l'intelligence des dames,
and, in conclusion, one by Guillaume Colletet, headed:
Question célèbre, s'il est nécessaire ou non que les filles soient
savantes, agitée de part et d'autre par Mlle Anne Marie de
Schurmann, hollandoise, et André Rivet, poictevin, le tout mis
en françois par le sieur Colletet (1646).
[11] La Nouvelle Colonie, ou la Ligue des Femmes, first presented
in the Théâtre italien on the 18th of April 1729, a three-act comedy,
afterwards reduced to one single act to be performed in the
théâtres de société, and published in this form in the Mercure. (Cf.
Larroumet; Marivaux, sa Vie et ses Oeuvres, Paris 1882).
[12] Such, at least, is the description of Mme Geoffrin's character in
M. E. Pilon's Portraits français. M. G. Lanson, in his Lettres du dix-
huitième siècle, accuses her of vanity and consequent despotic
leanings. Elle aimait à conseiller ses amis, et les régentait en mère
un peu despotique; elle n'aimait pas les indépendants, les âmes
indociles et fières qui ne se laissent pas protéger, et veulent être
consultés dans le bien qu'on leur fait.
[13] That a great many of the Utilitarian ideas of John Locke may be
traced to their origin in the works of Montaigne has been
demonstrated by M. Pierre Villey in his L'influence de Montaigne sur
les Idées pédagogiques de Locke et de Rousseau, who thus claims
for the literature of his own country an honour which was commonly
granted to that of England.
[14] The education recommended for Emile is not domestic. He was
to be kept carefully isolated from the world, so as to escape its taint,
until such time as his character would be fully matured, placing him
above the reach of disastrous influences. A similar principle had
prevailed at Mme de Maintenon's establishment of St. Cyr.
CHAPTER IV.
Feminist and Anti-Feminist Tendencies among
the English Augustans.
In studying the march of feminism among the two rival nations on
either side the Channel, one cannot help being struck by the
remarkable lateness of anything resembling a feminist movement in
England. That the women of mediaeval England were looked down
upon, not only on account of their inferior muscular strength, but
also on the score of their supposed want of mental and moral
stability, appears but too plainly from the numerous scornful
references to the weaker sex in the literature of those days. The
Song-collections of the Transition Period clearly betray the esprit
gaulois in their brutal estimate of woman and in the tone of
undisguised contempt and ridicule which prevails whenever women
are the theme. The often-repeated story of the henpecked husband
and the shrewish wife contains a warning against marriage which,
although couched in the form of banter, evidently has its foundation
in the general conviction of female depravity. The early plays with
their brawling scenes and stock female characters were also most
unfavourable to women. Nor did the early Renaissance bring any
marked improvement either in the female morals or in the male
appreciation of them, for the satires against women continued with
hardly a refutation. The improvement which resulted in Ascham's
days from the awakening female interest in learning and in the
Caroline period from the introduction into poetry of the Platonic love
ideal, was too partial and too qualified to be permanent, and in later
years the Puritanic ideal of womanhood was an abomination to
feminists of the Wollstonecraft type. But the general estimate of
women in England had never been lower than in the notorious days
that followed the Restoration. In the Middle Ages all influence had
been denied them on the score of their supposed inferiority of
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.
Let us accompany you on the journey of exploring knowledge and
personal growth!
ebookluna.com

More Related Content

Similar to (eBook PDF) Introduction to Programming with Java: A Problem Solving Approach 3rd Edition (20)

PDF
An Introduction to Network Programming with Java 1st Edition Jan Graba
lroxsyb839
 
PDF
Starting Out with C++: From Control Structures through Objects 8th Edition, (...
battonezsias
 
PDF
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
biprolarebo
 
PDF
(eBook PDF) Starting Out with C++: From Control Structures through Objects, B...
cursonshiwaa
 
PDF
[Ebooks PDF] download C How to Program 1ST Edition Harvey M. Deitel full chap...
raaenvalko0u
 
PDF
JAVA J2EE Training in Coimbatore - Fundamentals of Java J2EE
abile technologies
 
PDF
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
ghpgrgeci0297
 
PDF
Core Java Vol 1 2 For The Impatient And Effective Pack 12th Ed Cay S Horstmann
makozoleva
 
PDF
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
moinaurick62
 
PPTX
Java 8 - New Updates and Why It Matters?
CTE Solutions Inc.
 
PDF
JavaServer Pages 2nd Edition Larne Pekowsky
nemenjaic15
 
PDF
Apress.html5.and.java script.projects.oct.2011
Samuel K. Itotia
 
PDF
Scala a case4
lee.gilbert
 
PPTX
object oriented programming concept in java.pptx
Nagasivaparvathi
 
PPT
Features java9
srmohan06
 
ODP
Synapse India Reviews
Synapseindiappsdevelopment
 
PDF
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
cursonshiwaa
 
PDF
Learn Advanced Java Programming With Beginners Md Pulok
lwafaziurka
 
PDF
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
tdcpastwa
 
PPTX
Follow these reasons to know java’s importance
nishajj
 
An Introduction to Network Programming with Java 1st Edition Jan Graba
lroxsyb839
 
Starting Out with C++: From Control Structures through Objects 8th Edition, (...
battonezsias
 
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
biprolarebo
 
(eBook PDF) Starting Out with C++: From Control Structures through Objects, B...
cursonshiwaa
 
[Ebooks PDF] download C How to Program 1ST Edition Harvey M. Deitel full chap...
raaenvalko0u
 
JAVA J2EE Training in Coimbatore - Fundamentals of Java J2EE
abile technologies
 
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
ghpgrgeci0297
 
Core Java Vol 1 2 For The Impatient And Effective Pack 12th Ed Cay S Horstmann
makozoleva
 
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
moinaurick62
 
Java 8 - New Updates and Why It Matters?
CTE Solutions Inc.
 
JavaServer Pages 2nd Edition Larne Pekowsky
nemenjaic15
 
Apress.html5.and.java script.projects.oct.2011
Samuel K. Itotia
 
Scala a case4
lee.gilbert
 
object oriented programming concept in java.pptx
Nagasivaparvathi
 
Features java9
srmohan06
 
Synapse India Reviews
Synapseindiappsdevelopment
 
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
cursonshiwaa
 
Learn Advanced Java Programming With Beginners Md Pulok
lwafaziurka
 
(eBook PDF) Starting Out with C++: From Control Structures through Objects 8t...
tdcpastwa
 
Follow these reasons to know java’s importance
nishajj
 

Recently uploaded (20)

PPT
M&A5 Q1 1 differentiate evolving early Philippine conventional and contempora...
ErlizaRosete
 
PDF
Wikinomics How Mass Collaboration Changes Everything Don Tapscott
wcsqyzf5909
 
PDF
THE PSYCHOANALYTIC OF THE BLACK CAT BY EDGAR ALLAN POE (1).pdf
nabilahk908
 
PPTX
How to use _name_search() method in Odoo 18
Celine George
 
PDF
Andreas Schleicher_Teaching Compass_Education 2040.pdf
EduSkills OECD
 
PPTX
ENGLISH -PPT- Week1 Quarter1 -day-1.pptx
garcialhavz
 
PDF
Free eBook ~100 Common English Proverbs (ebook) pdf.pdf
OH TEIK BIN
 
PPTX
Martyrs of Ireland - who kept the faith of St. Patrick.pptx
Martin M Flynn
 
PPTX
How to Add New Item in CogMenu in Odoo 18
Celine George
 
PPTX
A Case of Identity A Sociological Approach Fix.pptx
Ismail868386
 
PPTX
Photo chemistry Power Point Presentation
mprpgcwa2024
 
PDF
The Power of Compound Interest (Stanford Initiative for Financial Decision-Ma...
Stanford IFDM
 
PPTX
Aerobic and Anaerobic respiration and CPR.pptx
Olivier Rochester
 
DOCX
ANNOTATION on objective 10 on pmes 2022-2025
joviejanesegundo1
 
PPTX
How to Configure Refusal of Applicants in Odoo 18 Recruitment
Celine George
 
PPTX
2025 Completing the Pre-SET Plan Form.pptx
mansk2
 
PPTX
How to Setup Automatic Reordering Rule in Odoo 18 Inventory
Celine George
 
PDF
Nanotechnology and Functional Foods Effective Delivery of Bioactive Ingredien...
rmswlwcxai8321
 
PDF
CAD25 Gbadago and Fafa Presentation Revised-Aston Business School, UK.pdf
Kweku Zurek
 
PDF
Gladiolous Cultivation practices by AKL.pdf
kushallamichhame
 
M&A5 Q1 1 differentiate evolving early Philippine conventional and contempora...
ErlizaRosete
 
Wikinomics How Mass Collaboration Changes Everything Don Tapscott
wcsqyzf5909
 
THE PSYCHOANALYTIC OF THE BLACK CAT BY EDGAR ALLAN POE (1).pdf
nabilahk908
 
How to use _name_search() method in Odoo 18
Celine George
 
Andreas Schleicher_Teaching Compass_Education 2040.pdf
EduSkills OECD
 
ENGLISH -PPT- Week1 Quarter1 -day-1.pptx
garcialhavz
 
Free eBook ~100 Common English Proverbs (ebook) pdf.pdf
OH TEIK BIN
 
Martyrs of Ireland - who kept the faith of St. Patrick.pptx
Martin M Flynn
 
How to Add New Item in CogMenu in Odoo 18
Celine George
 
A Case of Identity A Sociological Approach Fix.pptx
Ismail868386
 
Photo chemistry Power Point Presentation
mprpgcwa2024
 
The Power of Compound Interest (Stanford Initiative for Financial Decision-Ma...
Stanford IFDM
 
Aerobic and Anaerobic respiration and CPR.pptx
Olivier Rochester
 
ANNOTATION on objective 10 on pmes 2022-2025
joviejanesegundo1
 
How to Configure Refusal of Applicants in Odoo 18 Recruitment
Celine George
 
2025 Completing the Pre-SET Plan Form.pptx
mansk2
 
How to Setup Automatic Reordering Rule in Odoo 18 Inventory
Celine George
 
Nanotechnology and Functional Foods Effective Delivery of Bioactive Ingredien...
rmswlwcxai8321
 
CAD25 Gbadago and Fafa Presentation Revised-Aston Business School, UK.pdf
Kweku Zurek
 
Gladiolous Cultivation practices by AKL.pdf
kushallamichhame
 
Ad

(eBook PDF) Introduction to Programming with Java: A Problem Solving Approach 3rd Edition

  • 1. (eBook PDF) Introduction to Programming with Java: A Problem Solving Approach 3rd Edition download https://ebookluna.com/product/ebook-pdf-introduction-to- programming-with-java-a-problem-solving-approach-3rd-edition/ Download full version ebook from https://ebookluna.com
  • 2. John Dean Park University Raymond Dean University of Kansas JAVA WITH A Problem Solving Approach Introduction to Programming dea75768_fm_i-xxxviii.indd 1 4/30/20 11:54 AM
  • 3. 12.10. Empty Statement 552 12.11. Using break to Exit from a Loop 554 12.12. for Loop Header Details 555 12.13. Enumerated Types 557 12.14. forEach Method, Lambda Expressions, Method References, and Streams 564 12.15. Hexadecimal, Octal, and Binary Numbers 573 12.16. GUI Track: Unicode (Optional) 574 12.17. Introduction to GridWorld Case Study (Optional) 579 CHAPTER 13 Aggregation, Composition, and Inheritance 591 13.1. Introduction 592 13.2. Composition and Aggregation 592 13.3. Inheritance Overview 599 13.4. Implementation of a Person/Employee/ FullTime Hierarchy 603 13.5. Constructors in a Subclass 605 13.6. Method Overriding 606 13.7. Using the Person/Employee/FullTime Hierarchy 609 13.8. The final Access Modifier 610 13.9. Using Inheritance with Aggregation and Composition 610 13.10. Design Practice with Card Game Example 613 13.11. GridWorld Case Study Extensions (Optional) 619 13.12. Problem Solving with Association Classes (Optional) 626 CHAPTER 14 Inheritance and Polymorphism 637 14.1. Introduction 638 14.2. The Object Class and Automatic Type Promotion 638 14.3. The equals Method 639 14.4. The toString Method 643 14.5. Polymorphism and Dynamic Binding 648 14.6. Assignments When the Two Sides’ Classes Are Different 653 14.7. Polymorphism with Arrays 654 14.8. abstract Methods and Classes 660 14.9. Interfaces 663 14.10. The protected Access Modifier 673 14.11. GUI Track: Three-Dimensional Graphics (Optional) 677 CHAPTER 15 Exception Handling 691 15.1. Introduction 692 15.2. Overview of Exceptions and Exception Messages 692 15.3. Using try and catch Blocks to Handle “Dangerous” Method Calls 693 15.4. Line Plot Example 695 15.5. try Block Details 699 15.6. Two Categories of Exceptions—Checked and Unchecked 700 15.7. Unchecked Exceptions 702 15.8. Checked Exceptions 705 15.9. Generic catch Block with Exception Class 708 15.10. Multiple catch Blocks and Multiple Exceptions per Block 712 15.11. Understanding Exception Messages 714 15.12. Using a throws Clause to Postpone the catch 718 15.13. Automatic Cleanup Using Try-With- Resources 720 15.14. GUI Track: Line Plot Example Revisited (Optional) 722 CHAPTER 16 Files, Buffers, Channels, and Paths 735 16.1. Introduction 736 16.2. Simple Text-File Example: HTML File Generator 737 16.3. A Website Reader 741 16.4. Object File I/O 743 16.5. Character Sets and File-Access Options 748 16.6. Buffered Text File I/O 749 16.7. Primitive Buffers with Random Access 752 16.8. Channel I/O and Memory-Mapped Files 760 viii Contents dea75768_fm_i-xxxviii.indd 8 4/30/20 11:54 AM
  • 4. 16.9. Path, Whole-File, and Directory Operations 767 16.10. Walking a Directory Tree 769 16.11. GUI Track: Final Iteration of Problem Solving with CRC Cards (Optional) 775 CHAPTER 17 GUI Programming Basics 787 17.1. Introduction 788 17.2. SimpleWindow Program 791 17.3. Stage and Scene 794 17.4. JavaFX Components 796 17.5. Label Control 797 17.6. TextField Control 799 17.7. Greeting Program 801 17.8. Event Handling 805 17.9. Property Binding 809 17.10. JavaFX CSS 812 17.11. Scene Graph Inheritance 818 17.12. Style Sheets and Cascading 821 17.13. Button Control and FactorialButton Program 826 17.14. Distinguishing Between Multiple Events 832 17.15. Colors 834 17.16. ColorChooser Program 838 CHAPTER 18 GUI Programming—Layout Panes 849 18.1. Introduction 849 18.2. Layout Panes 851 18.3. FlowPane and GridPane—Competing Layout Philosophies 853 18.4. VBox Program with Two Stages and an Image File 858 18.5. BorderPane 867 18.6. TilePane and TextFlow Containers 872 18.7. TicTacToe Program 878 18.8. Embedded Panes, HBox, and MathCalculator Program 882 18.9. Plain Pane Container and Component Positioning 889 CHAPTER 19 GUI Programming—Additional GUI Components, Additional Event Handlers, Animation 896 19.1. Introduction 897 19.2. User Interface Design 897 19.3. TextArea Control 898 19.4. CheckBox and RadioButton Controls 903 19.5. ComboBox Control 909 19.6. Job Application Program 913 19.7. ScrollPane and Menu Classes 918 19.8. Images and Mouse Events 922 19.9. Lunar Eclipse Program with Circle, RadialGradient, and Slider 928 19.10. Animation 933 Appendices Appendix 1 ASCII Character Set 943 Appendix 2 Operator Precedence 945 Appendix 3 Java Keywords and Other Reserved Words 947 Appendix 4 Packages and Modules 951 Appendix 5 Java Coding-Style Conventions 963 Appendix 6 Javadoc with Tags 975 Appendix 7 UML Diagrams 980 Appendix 8 Number Systems and Conversions Between Them 986 Additional Online Material Chapter S6 Writing Methods in a Non-Object- Oriented Environment Chapter S9 Arrays in a Non-Object-Oriented Environment Chapter S17 GUI Programming Basics Chapter S18 GUI Programming—Component Layout, Additional GUI Components Appendix 9 Multithreading Index 990 Contents ix dea75768_fm_i-xxxviii.indd 9 5/12/20 1:41 PM
  • 5. x In this book, we lead you on a journey into the fun and exciting world of computer programming. Through- out your journey, we’ll provide you with lots of problem-solving practice. After all, good programmers need to be good problem solvers. We’ll show you how to implement your problem solutions with Java programs. We provide a plethora of examples, some short and focused on a single concept, some longer and more “real world.” We present the material in a conversational, easy-to-follow manner aimed at making your journey a pleasant one. When you’re done with the book, you should be a proficient Java programmer. Our textbook targets a wide range of readers. Primarily, it targets students in a standard college-level “Introduction to Programming” course or course sequence where no prerequisite programming experience is assumed. We have included the topics recommended by the College Board for high school students studying for advanced placement (AP) in computer science. So this text should be good for those students as well. In addition to targeting students with no prerequisite programming experience, our textbook targets industry practitioners and college-level students who have some programming experience and want to learn Java. This second set of readers can skip the early chapters on general programming concepts and focus on the features of Java that differ from the languages that they already know. In particular, because C++ and Java are similar, readers with a C++ background should be able to cover the textbook in a single three-credit-hour course. (But we should reiterate for those of you with no programming experience: No prerequisite programming experience is required in order to use this text.) Finally, our textbook targets those who are learning Java on their own, outside of a classroom environ- ment. This third set of readers should read the entire textbook at a pace determined on a case-by-case basis. What’s New in This Edition? The changes in this edition are big and small. Big changes include new chapters, reorganized chapter sec- tions, new programming constructs, new program examples, and new exercises. Smaller changes include updating explanations and anecdotes. We’ve combed the entire book for opportunities to improve the book’s clarity and readability. The following list highlights the more significant changes that we’ve made to this edition. ∙ Introductory Chapter To keep up with the computer industry’s growth, we’ve made quite a few changes to Chapter 1, such as updating the information in the computer hardware and Java history sections. ∙ Switching Constructs Java 12 and Java 13 made improvements to the venerable switch statement, and this edition describes those improvements. We use the new switching techniques (multiple comma-­ separated case constants and no break statements) for programs throughout the book. And we use switch statements versus switch expressions according to what the problem calls for. If you’re a fan of the old-style switch statement, no worries, we provide a description early on which will help you with legacy code. Preface dea75768_fm_i-xxxviii.indd 10 4/30/20 11:54 AM
  • 6. Preface xi ∙ Local Variable Type Inferencing Java 10 introduced the ability to use var as a type (rather than int, double, etc.) for a local variable declaration where the declaration is part of an initialization. We describe the new syntax, but for self- documentation reasons, we stick with traditional explicit type declarations for the most part. ∙ Name Change for Static Variables and Static Methods The powers that be (the Oracle documentation folks) now use the terms static variable and static method for what used to be known as class variable and class method, so we’ve updated accordingly. ∙ Miscellaneous Java API Library Updates With the new Java releases since the second edition, there have been quite a few updates to the Java API library. We’ve updated our discussions and programs with new API method and constructor calls when appropriate. Most of our new API content can be found in our GUI coverage, but there are other API changes sprinkled throughout the book. For example, with Java’s deprecation of the wrapper class constructors, we’ve refactored our programs to rely on the wrapper classes’ valueOf methods. ∙ New Section—forEach Method and Streams We introduce the forEach method as a simple alternative to the for-each loop in the context of an ArrayList. We then use the forEach method in the context of streams, where it really shines. We describe streams in depth, with their exciting potential to take advantage of parallel processing to improve a program’s efficiency. ∙ Lambda Expressions and Method References Lambda expressions and method references are techniques that allow you to implement the function- ality of a method so you can use it as an argument in a method call. We first present lambda expres- sions and method references as arguments for a forEach method call. Later, we use lambda expressions and method references extensively to help with the GUI programs. ∙ Interfaces with Static Methods and Default Methods We’ve rewritten Chapter 14’s section on interfaces to include a discussion of static methods and default methods. Oracle added them to interfaces because they support an interface’s ability to imple- ment multiple inheritance effectively. ∙ End-of-Chapter GUI Sections We’ve rewritten all of our end-of-chapter GUI sections to take advantage of Java’s newer GUI constructs. ∙ Three New Chapters—JavaFX In this book’s second edition, we used the AWT and Swing platforms for our two GUI chapters. This third edition moves those chapters to the book’s website. We provide three new chapters in the main body of the book that describe GUI programming using the JavaFX platform. As part of that presenta- tion, you’ll learn how to format your programs using JavaFX CSS properties. ∙ New Appendix—Modules In Appendix 4, we introduce modules, which allow you to group together packages. Modules make it easier to organize and share classes for different programming needs. They are used to facilitate the configuration of Java software for diverse hardware and software platforms. dea75768_fm_i-xxxviii.indd 11 5/10/20 8:49 PM
  • 7. xii Preface ∙ New Exercises We have substantially changed most of the exercises and altered almost all of them in some way. As before, we provide exercise solutions on the password-protected instructor’s portion of the book’s website. Compliant with the College Board’s AP Computer Science A Curriculum We have put a great deal of effort into ensuring that this textbook is compliant with the College Board’s Advanced Placement (AP) Computer Science A curriculum content. It follows all the AP Computer Science A guidelines. As such, it appears on the College Board’s approved textbook list at https://apcentral.collegeboard.org/courses/ap-computer-science-a/course-audit. Textbook Cornerstone #1: Problem Solving Being able to solve problems is a critical skill that all programmers must possess. We teach programmatic problem solving by emphasizing two of its key elements—algorithm development and program design. Emphasis on Algorithm Development In Chapter 2, we immerse readers into algorithm development by using pseudocode for the algorithm examples instead of Java. In using pseudocode, students are able to work through nontrivial problems on their own without getting bogged down in Java syntax—no need to worry about class headings, semico- lons, braces, and so on.1 Working through nontrivial problems enables students to gain an early apprecia- tion for creativity, logic, and organization. Without that appreciation, Java students tend to learn Java syntax with a rote-memory attitude. But with that appreciation, students tend to learn Java syntax more quickly and effectively because they have a motivational basis for learning it. In addition, they are able to handle nontrivial Java homework assignments fairly early because they have prior experience with simi- larly nontrivial pseudocode homework assignments. In Chapter 3 and in later chapters, we rely primarily on Java for algorithm-development examples. But for the more involved problems, we sometimes use high-level pseudocode to describe first-cut proposed solutions. Using pseudocode enables readers to bypass syntax details and focus on the algorithm portion of the solution. Emphasis on Program Design Problem solving is more than just developing an algorithm. It also involves figuring out the best imple- mentation for the algorithm. That’s program design. Program design is extremely important, and that’s why we spend so much time on it. Frequently, we explain the thought processes that a person might go through when coming up with a solution. For example, we explain how to choose between different loop types, how to split up a method into multiple methods, how to decide on appropriate classes, how to 1 Inevitably, we use a particular style for our pseudocode, but we repeatedly emphasize that other pseudocode styles are fine so long as they convey the intended meaning. Our pseudocode style is a combination of free-form description for high-level tasks and more specific commands for low-level tasks. We’ve chosen a pseudocode style that is intuitive, to welcome new programmers, and struc- tured, to accommodate program logic. dea75768_fm_i-xxxviii.indd 12 4/30/20 11:54 AM
  • 8. Preface xiii choose between instance and static members, and how to determine class relationships using inheritance and composition. We challenge students to find the most elegant implementations for a particular task. We devote a whole chapter to program design—Chapter 8, “Software Engineering.” In that chapter, we provide an in-depth look at coding-style conventions and documentation for programmers and users. We discuss design strategies like separation of concerns, modularization, and encapsulation. Also in the chapter, we describe alternative design strategies—top-down, bottom-up, case-based, and iterative enhancement. Problem-Solving Sections We often address problem solving (algorithm development and program design) in the natural flow of explaining concepts. But we also cover problem solving in sections that are wholly devoted to it. In each problem-solving section, we present a situation that contains an unresolved problem. In coming up with a solution for the problem, we try to mimic the real-world problem-solving experience by using an iterative design strategy. We present a first-cut solution, analyze the solution, and then discuss possible improve- ments to it. We use a conversational trial-and-error format (e.g., “What type of layout manager should we use? We first tried the GridLayout manager. That works OK, but not great. Let’s now try the BorderLayout manager.”). This casual tone sets the student at ease by conveying the message that it is normal, and in fact expected, that a programmer will need to work through a problem multiple times before finding the best solution. Additional Problem-Solving Mechanisms We include problem-solving examples and problem-solving advice throughout the text (not just in Chapter 2, Chapter 8, and the problem-solving sections). As a point of emphasis, we insert a problem- solving box, with an icon and a succinct tip, next to the text that contains the problem-solving example and/or advice. We are strong believers in learning by example. As such, our textbook contains a multitude of com- plete program examples. Readers are encouraged to use our programs as recipes for solving similar pro- grams on their own. Textbook Cornerstone #2: Fundamentals First Postpone Concepts That Require Complex Syntax We feel that many introductory programming textbooks jump too quickly into concepts that require com- plex syntax. In using complex syntax early, students get in the habit of entering code without fully under- standing it or, worse yet, copying and pasting from example code without fully understanding the example code. That can lead to less-than-ideal programs and students who are limited in their ability to solve a wide variety of problems. Thus, we prefer to postpone concepts that require complex syntax. We prefer to intro- duce such concepts later on, when students are better able to understand them fully. As a prime example of that philosophy, we cover the simpler forms of GUI programming early (in an optional graphics track), but we cover the more complicated forms of GUI programming later in the book. Specifically, we postpone event-driven GUI programming until the end of the book. This is dif- ferent from some other Java textbooks, which favor early full immersion into event-driven GUI pro- gramming. We feel that strategy is a mistake because proper event-driven GUI programming requires a great deal of programming maturity. When they learn it at the end of the book, our readers are better able to understand it fully. dea75768_fm_i-xxxviii.indd 13 4/30/20 11:54 AM
  • 9. xiv Preface Tracing Examples To write code effectively, it’s imperative to understand code thoroughly. We’ve found that step-by-step tracing of program code is an effective way to ensure thorough understanding. Thus, in the earlier parts of the textbook, when we introduce a new programming structure, we often illustrate it with a meticulous trace. The detailed tracing technique we use illustrates the thought process programmers employ while debugging. It’s a printed alternative to the sequence of screen displays generated by debuggers in inte- grated development environment (IDE) software. Input and Output In the optional GUI-track sections and in the GUI chapters at the end of the book, we use GUI commands for input and output (I/O). But because of our emphasis on fundamentals, we use console commands for I/O for the rest of the book.2 For console input, we use the Scanner class. For console output, we use the standard System.out.print, System.out.println, and System.out.printf methods. Textbook Cornerstone #3: Real World More often than not, today’s classroom students and industry practitioners prefer to learn with a hands- on, real-world approach. To meet this need, our textbook and its associated website include: ∙ compiler tools ∙ complete program examples ∙ practical guidance in program design ∙ coding-style guidelines based on industry standards ∙ Unified Modeling Language (UML) notation for class relationship diagrams ∙ practical homework-project assignments Compiler Tools We do not tie the textbook to any particular compiler tool—you are free to use any compiler tool(s) that you like. If you do not have a preferred compiler in mind, then you might want to try out one or more of these: ∙ Java Standard Edition Development Kit (JDK), by Oracle ∙ TextPad, by Helios ∙ Eclipse, by the Eclipse Foundation ∙ Netbeans, backed by Oracle ∙ BlueJ, by the University of Kent and Deaken University To obtain the above compilers, visit our textbook website at http://www.mhhe.com/dean3e, find the appropriate compiler link(s), and download away for free. Complete Program Examples In addition to providing code fragments to illustrate specific concepts, our textbook contains lots of com- plete program examples. With complete programs, students are able to (1) see how the analyzed code ties in with the rest of a program, and (2) test the code by running it. 2 We introduce GUI I/O at the end of Chapter 3 with dialog boxes. That opens up an optional door for GUI fans. If readers are so inclined, they can use the Alert, TextInputDialog, and ChoiceDialog classes to implement all our programs with GUI I/O rather than console I/O. dea75768_fm_i-xxxviii.indd 14 4/30/20 11:54 AM
  • 10. Preface xv Coding-Style Conventions We include coding-style tips throughout the textbook. The coding-style tips are based on Oracle’s coding conventions (https://www.oracle.com/technetwork/java/codeconvtoc-136057.html), Google’s coding con- ventions (https://google.github.io/styleguide/javaguide.html), and industry practice. In Appendix 5, we provide a complete reference for the book’s coding-style conventions and an associated example program that illustrates these conventions. UML Notation UML has become a standard for describing the entities in large software projects. Rather than overwhelm beginning programmers with syntax for the entire UML (which is quite extensive), we present a subset of UML. Throughout the textbook, we incorporate UML notation to represent classes and class relationships pictorially. For those interested in more details, we provide additional UML notation in Appendix 7. Homework Problems We provide homework problems that are illustrative, practical, and clearly worded. The problems range from easy to challenging. They are grouped into three categories—review questions, exercises, and proj- ects. We include review questions and exercises at the end of each chapter, and we provide projects on our textbook’s website. The review questions tend to have short answers, and the answers are in the textbook. The review questions use these formats: short-answer, multiple-choice, true/false, fill-in-the-blank, tracing, debugging, and write a code fragment. Each review question is based on a relatively small part of the chapter. The exercises tend to have short to moderate-length answers, and the answers are not in the textbook. The exercises use these formats: short-answer, tracing, debugging, and write a code fragment. Exercises are keyed to the highest prerequisite section number in the chapter, but they sometimes integrate concepts from several parts of the chapter. For this third edition, we have changed almost all of the end-of-chapter exercises, including exercises associated with unchanged material in the body of the text. The projects consist of problem descriptions whose solutions are complete programs. Project solu- tions are not in the textbook. Projects require students to employ creativity and problem-solving skills and apply what they’ve learned in the chapter. These projects often include optional parts, which provide chal- lenges for the more talented students. Projects are keyed to the highest prerequisite section number in the chapter, but they often integrate concepts from several preceding parts of the chapter. For this third edition, we have modified old projects and added new projects to make all projects conform to content in the body of the current text. Because the most substantial body-of-text changes are in the final three chapters, most of the project modifications and additions are associated with these chapters. An important special feature of this book is the way that it specifies problems. “Sample sessions” show the precise output generated for a particular set of input values. These sample sessions include inputs that represent typical situations and sometimes also extreme or boundary situations. Academic-Area Projects To enhance the appeal of projects and to show how the current chapter’s programming techniques might apply to different areas of interest, we take project content from several academic areas: ∙ computer science and numerical methods ∙ business and accounting dea75768_fm_i-xxxviii.indd 15 4/30/20 11:54 AM
  • 11. xvi Preface ∙ social sciences and statistics ∙ math and physics ∙ engineering and architecture ∙ biology and ecology Most of the academic-area projects do not require prerequisite knowledge in a particular area. Thus, instructors are free to assign almost any of the projects to any of their students. To provide a general reader with enough specialized knowledge to work a problem in a particular academic area, we sometimes expand the problem statement to explain a few special concepts in that academic area. Most of the academic-area projects do not require students to have completed projects from earlier chapters; that is, most projects do not build on previous projects. Thus, for the most part, instructors are free to assign projects without worrying about prerequisite projects. In some cases, a project repeats a previous chapter’s project with a different approach. The teacher may elect to take advantage of this rep- etition to dramatize the availability of alternatives, but this is not necessary. Project assignments can be tailored to fit readers’ needs. For example: ∙ For readers outside of academia— Readers can choose projects that match their interests. ∙ When a course has students from one academic area— Instructors can assign projects from the relevant academic area. ∙ When a course has students with diverse backgrounds— Instructors can ask students to choose projects from their own academic areas, or instructors can ignore the academic-area delineations and simply assign projects that are most appealing. To help you decide which projects to work on, we’ve included a “Project Summary” section after the preface. It lists all the projects by chapter and section, and for each project, it specifies: ∙ prerequisite chapter and section ∙ academic area ∙ estimated difficulty ∙ a title and brief description After using the “Project Summary” section to get an idea of which projects you might like to work on, see the textbook’s website for the full project descriptions. Organization In writing this book, we lead readers through three important programming methodologies: structured programming, OOP, and event-driven programming. For our structured programming coverage, we intro- duce basic concepts such as variables and operators, if statements, and loops. Then we show readers how to call prebuilt methods from Oracle’s Java API library. Many of these methods, like those in the Math class, are non-OOP methods that can be called directly. Others, like those in the String class, are OOP methods that must be called by a previously created object. After an “interlude” that gives readers a brief taste of what it’s like to write methods in a non-OOP environment, we move into OOP programming, and introduce basic OOP concepts such as classes, objects, instance variables, instance methods, and construc- tors. We also introduce static variables and static methods, which are useful in certain situations. However, we note that they should be used less often than instance variables and instance methods. Next, we move dea75768_fm_i-xxxviii.indd 16 4/30/20 11:54 AM
  • 12. Preface xvii on to more advanced OOP concepts—arrays, collections, interfaces, and inheritance. Chapters on excep- tion handling and files provide a transition into event-driven GUI programming. We describe and employ event-driven GUI programming in the final three chapters. The content and sequence we promote enable students to develop their skills from a solid foundation of programming fundamentals. To foster this fundamentals-first approach, our book starts with a mini- mum set of concepts and details. It then gradually broadens concepts and adds detail later. We avoid over- loading early chapters by deferring certain less-important details to later chapters. GUI Track Many programmers find Graphical User Interface (GUI) programming to be fun. As such, GUI program- ming can be a great motivational tool for keeping readers interested and engaged. That’s why we include graphics sections throughout the book, starting in Chapter 1. We call those sections our “GUI track.” Most of these end-of-chapter sections use GUI code that complements the current chapter’s previously pre- sented non-GUI material. For readers who do not have time for the GUI track, no problem. Any or all of the GUI track sections may be skipped because the rest of the book does not depend on any of the GUI- track material. Although the rest of the book does not depend on the GUI-track material, be aware that some of the GUI-track sections depend on some of the material in prior GUI-track sections: ∙ Chapter 3’s GUI section introduces dialog boxes for user input, and dialog boxes are used in later GUI sections for Chapters 10, 11, 15, and 16. ∙ Chapters 8, 10, and 16 have GUI sections that implement a common program, with iterative enhance- ments in each new GUI section. ∙ Chapters 12 and 13 have GUI sections that implement a common GridWorld program (for readers interested in the College Board’s AP Computer Science A curriculum). The GridWorld code uses AWT and Swing GUI software. Chapter 1 In Chapter 1, we first explain basic computer terms—what are the hardware components, what is source code, what is object code, and so on. We then narrow our focus and describe the programming language we’ll be using for the remainder of the book—Java. Finally, we give students a quick view of the classic bare-bones “Hello World” program. We explain how to create and run the program using minimalist­ software—Microsoft’s Notepad text editor and Oracle’s command-line JDK tools. Chapter 2 In Chapter 2, we present problem-solving techniques with an emphasis on algorithmic design. In imple- menting algorithm solutions, we use generic tools—flowcharts and pseudocode—with pseudocode given greater weight. As part of our algorithm-design explanation, we describe structured programming tech- niques. In order to give students an appreciation for semantic details, we show how to trace algorithms. Chapters 3–5 We present structured programming techniques using Java in Chapters 3–5. Chapter 3 describes sequential programming basics—variables, input/output, assignment statements, and simple method calls. Chapter 4 describes nonsequential program flow—if statements, switch constructs, and loops. In Chapter 5, we explain methods in more detail and show readers how to use prebuilt methods in the Java API library. dea75768_fm_i-xxxviii.indd 17 4/30/20 11:54 AM
  • 13. xviii Preface In all three chapters, we teach algorithm design by solving problems and writing programs with the newly introduced Java syntax. Interlude This “mini-chapter” contains two programs that show how to write multiple methods without using OOP. The Interlude presents a fork in the road between two study sequences. For the standard study sequence, read the chapters in the standard order (Chapters 1 through 19). For the “objects later” study sequence, after reading Chapter 5, read the supplemental chapters S6 and S9 online before returning to Chapter 6, where you’ll begin your study of OOP in earnest. Chapters 6–7 Chapter 6 introduces the basic elements of OOP in Java. This includes implementing classes and imple- menting methods and variables within those classes. We use UML class diagrams and object-oriented tracing techniques to illustrate these concepts. Chapter 7 provides additional OOP details. It explains how reference variables are assigned, tested for equality, and passed as arguments to a method. It explains overloaded methods and constructors. It also explains the use of static variables, static methods, and different types of named constants. Chapter 8 While the art of program design and the science of computerized problem-solving are developed through- out the textbook, in Chapter 8, we focus on these aspects in the context of OOP. This chapter begins with an organized treatment of programming style. It introduces javadoc, the Java application that automati- cally generates documentation for user-programmers. It describes ways to communicate with users who are not programmers. It describes organizational strategies like separation of concerns, modularization, encapsulation, and provision of general-purpose utilities. Coded examples show how to implement these strategies. It describes the major programming paradigms—top-down design, bottom-up design, using pre-written software for low-level modules, and prototyping. Chapters 9–10 Chapter 9 describes arrays, including arrays of primitives, arrays of objects, and multidimensional arrays. It illustrates array use with complete programs that sort, search, and construct histograms. Chapter 10 describes Java’s powerful array alternative, ArrayList. This provides a simple example of generic-­element specification. It also introduces the Java Collections Framework, which in turn, provides natural illustrations of Java interfaces. The prewritten classes in the Java Collections Framework provide a simple introduction of sets, maps, and queues. A relatively short but complete program shows how the pre-written Java implementa- tions of these data structures can be used to create and traverse a multiconnected random network. Chapter 11 Chapter 11 describes another way to process a collection of data—recursion. This chapter includes a ­ discussion of various recursive strategies. It introduces recursion with a real-life example and a familiar problem that one can solve easily with either looping or recursion. Then it moves gradually to problems that are harder to solve with looping and more easily solved with recursion. Although this chapter appears after the chapter on ArrayLists and the Java Collections Framework, it does not depend on these ­ concepts—it uses just ordinary arrays. dea75768_fm_i-xxxviii.indd 18 5/12/20 1:23 PM
  • 14. Preface xix Chapter 12 Early on, students need to be immersed in problem-solving activities. Covering too much syntax detail early can detract from that objective. Thus, we initially gloss over some less-important syntax details and come back to those details later in Chapter 12. This chapter provides more details on items such as these: ∙ byte and short primitive types ∙ Unicode character set ∙ type promotions ∙ postfix versus prefix modes for the increment and decrement operators ∙ conditional operator ∙ short-circuit evaluation ∙ enum data type ∙ forEach method ∙ lambda expressions ∙ method references ∙ streams The chapter ends with a friendly introduction to a relatively large public-domain program called Grid- World, which the College Board has used for many years as part of its AP Computer Science A course of study. This gives students a glimpse of how larger programs are organized. Chapters 13–14 Chapters 13 and 14 describe class relationships in depth with numerous examples. Chapter 13 describes aggregation, composition, and inheritance. Chapter 14 describes advanced inheritance-related details such as the Object class, polymorphism, abstract classes, and the finer points of interfaces. An optional section at the end of Chapter 13 describes an extension of the GridWorld environment introduced in Chapter 12 and provides additional exposure to Java’s legacy AWT and Swing graphics. Exercises in Chapters 13 and 14 relate material in these two chapters to corresponding GridWorld features. Chapters 15−16 Chapter 15 describes exception handling, and Chapter 16 describes files. We present exception handling before files because file-handling code requires the use of exception handling. For example, to open a file one must check for an exception. In addition to simple text I/O, our treatment of files includes buffering, random access, channeling, and memory mapping. Chapters 17−19 As in the end-of-chapter GUI sections, Chapters 17−19 present GUI concepts using the JavaFX platform. But the programming strategies differ. What follows are the strategies used in Chapters 17–19 (which are different from the strategies used in the end-of-chapter GUI sections). For user input, the programs use the components TextField, TextArea, Button, RadioButton, CheckBox, ComboBox, ScrollPane, and Menu. For layout, the programs use the containers FlowPane, VBox, HBox, GridPane, BorderPane, TilePane, and TextFlow. For formatting, the programs use JavaFX CSS properties. Depending on how much and what kind of GUI techniques you’re interested in, you can study one or more of the end-of-chapter GUI sections or skip all of them. That won’t affect your ability to grasp what’s in Chapters 17−19. If you’re short on time, you can omit all of the book’s GUI material without compro- mising your understanding of other material in the book. dea75768_fm_i-xxxviii.indd 19 5/10/20 8:50 PM
  • 15. xx Preface Chapters S17−S18 Chapters S17 and S18 (the S’s stand for supplemental) are posted online. They describe the older Java GUI platforms—AWT and Swing. The trend has been for new Java programs to use JavaFX, and not AWT and Swing. However, there’s quite a bit of AWT and Swing code currently in production, and that means there’s still a need for Java programmers to understand the older techniques so they can update and improve existing code. So if you find yourself in that position, Chapters S17 and S18 are a good starting point for learning what you need to know. Appendices Most of the appendices cover reference material, like the ASCII character set and the operator precedence table. For this third edition, we have updated Appendix 4 by including a detailed description of Java modules. Subject-Matter Dependencies and Sequence-Changing Opportunities We’ve positioned the textbook’s material in a natural order for someone who wants fundamentals and also wants an early introduction to OOP. We feel that our order is the most efficient and effective one for learning how to become a proficient OOP programmer. Nonetheless, we realize that different readers have different content- ordering preferences. To accommodate those different preferences, we’ve provided some built-in flexibility. Figure 0.1 illustrates that flexibility by showing chapter dependencies and, more importantly, chapter ­ nondependencies. For example, the arrow between Chapter 3 and Chapter 4 means that Chapter 3 must be read prior to Chapter 4. Because there are no arrows going out of Chapters 1, 11, and 16 that point to other complete chapters, you may skip those chapters without losing prerequisite material that later chapters need. We use rectangles with rounded corners to indicate chapter sections that you may want to read in advance. If you choose that option, you’ll want to return to the normal chapter sequence after completing the advanced sections. Here are some sequence-changing opportunities revealed by Figure 0.1: ∙ Readers can skip Chapter 1, “Introduction to Computers and Programming.” ∙ For an earlier introduction to OOP, readers can read the OOP overview section in Chapter 6 after reading Chapter 1. ∙ Readers can learn OOP syntax and semantics in Chapter 6 after finishing Java basics in Chapter 3. ∙ For additional looping practice, readers can learn about arrays in Chapter 9 after finishing loops in Chapter 4. ∙ Readers can skip Chapter 11, “Recursion,” and Chapter 16, “Files.” ∙ Readers who prefer a late objects approach can postpone reading Chapter 6, “Object-Oriented Pro- gramming,” by first reading Chapter S6, “Writing Methods in a Non-Object-Oriented Environment,” Sections 9.1–9.6 (which explain the basics of arrays), and Chapter S9, “Arrays in a Non-Object- Oriented Environment.” ∙ For GUI programming, readers who prefer the Swing platform should read Chapters S17 and S18. To support content-ordering flexibility, the book contains “hyperlinks.” A hyperlink is an optional jump forward from one place in the book to another place. The jumps are legal in terms of prerequisite knowledge, meaning that the jumped-over (skipped) material is unnecessary for an understanding of the later material. We supply hyperlinks for each of the nonsequential arrows in Figure 0.1. For example, we supply hyperlinks that go from Chapter 1 to Chapter 6 and from Chapter 3 to Chapter 12. For each hyperlink tail end (in the earlier chapter), we tell the reader where they may optionally jump to. For each hyperlink target end (in the later chapter), we provide an icon at the side of the target text that helps readers find the place where they are to begin reading. dea75768_fm_i-xxxviii.indd 20 5/12/20 1:24 PM
  • 16. Preface xxi Figure 0.1 Chapter dependencies Ch 5: Using Prebuilt Methods Ch 1: Introduction Ch 2: Algorithms and Design Ch 3: Java Basics Ch 4: Control Statements §6.2 OOP Overview §6.1−§6.8 OOP Basics §12.6−§12.12 Alternate Coding Mechanisms §9.1−§9.6 Arrays §12.1−§12.5 Type Details Interlude Ch 8: Software Engineering Ch 6: Object-Oriented Programming Ch 7: OOP−Additional Details §11.1−§11.5 Non- Array Recursion §9.1−§9.6 Array Basics Chapter S6: Writing Methods in a Non-Object- Oriented Environment Chapter S9: Arrays in a Non-Object-Oriented Environment Ch 9: Arrays Ch 10: ArrayList and Introduction to Java Collections Framework Ch 12: Type Details and Alternate Coding Mechanisms Ch 11: Recursion Ch 13: Aggregation, Composition and Inheritance Ch 16: Files Ch 14: Inheritance and Polymorphism Ch 15: Exception Handling Ch S17: Swing GUI Programming Basics Ch 17: GUI Programming Basics Ch 18: GUI Programming— Layout Panes Ch 19: GUI Programming— Additional GUI Components, Additional Event Handlers, Animation Ch S18: Swing GUI Component Layout, Additional GUI Components dea75768_fm_i-xxxviii.indd 21 4/30/20 11:54 AM
  • 17. xxii Preface Pedagogy Icons Program elegance. Indicates that the associated text deals with a program’s coding style, readability, maintainability, robustness, and scalability. Those qualities comprise a program’s elegance. Problem solving. Indicates that the associated text deals with problem-solving issues. Comments associated with this icon attempt to generalize highlighted material in the adjacent text. Common errors. Indicates that the associated text deals with common errors. Hyperlink target. Indicates the target end of a hyperlink. Program efficiency. Indicates that the associated text refers to program-efficiency issues. Student Resources At the textbook website, http://www.mhhe.com/dean3e, students (and also teachers) can view and down- load these resources: ∙ Links to compiler software—for Oracle’s JDK, Helios’s TextPad, Eclipse, NetBeans, and BlueJ ∙ TextPad tutorial ∙ Eclipse tutorials ∙ Student-version Microsoft PowerPoint lecture slides without hidden notes The student-version slides are identical to the teacher-version slides except that the hidden notes, hidden slides, and quizzes are omitted. Omitting the hidden notes forces the students to go to lecture to hear the sage on the stage fill in the blanks. ∙ GridWorld code ∙ Project assignments ∙ All textbook example programs and associated resource files ∙ Supplemental chapters ∙ Supplemental appendices Instructor Resources At the textbook website, http://www.mhhe.com/dean3e, instructors can view and download these resources: ∙ Teacher-version PowerPoint lecture slides with hidden notes Hidden notes provide comments that supplement the displayed text in the lecture slides. For example, if the displayed text asks a question, the hidden notes provide the answer. dea75768_fm_i-xxxviii.indd 22 4/30/20 11:55 AM
  • 18. Preface xxiii ∙ Exercise solutions ∙ Project solutions ∙ Test bank materials Acknowledgments The inspiration for this book is teaching, without which there would be no book. So thanks to the students who have used prior editions of the textbook and provided valuable feedback. What helps them to learn is what drives improvements in the book. And also a big thanks to the teachers who have used the book. With their diverse views from diverse backgrounds, we’re able to glean important insights that can help make the book approachable to a wider audience. Anyone who has written a textbook can attest to what a large and well-orchestrated team effort it requires. Such a book can never be the work of only one person, or even a few people. We are deeply indebted to the team at McGraw-Hill Higher Education who have shown continued faith in our writing and invested generously in it. It has been a pleasure to work with Product Developer Heather Ervolino, who has overseen this third edition’s development process. Helping us through the various stages of this edition’s production was Project Manager Jason Stauter. We would also like to thank Senior Marketing Manager Shannon O’Donnell, who helped in the final stages. All the professionals we have encountered throughout the McGraw-Hill organization have been won- derful to work with, and we sincerely appreciate their efforts. We would like to acknowledge with appreciation the numerous and valuable comments, suggestions, and constructive criticisms, and praise from the many instructors who have reviewed this edition and prior editions of the book. In particular, Christopher Crick, Oklahoma State University Christopher Taylor, Milwaukee School of Engineering Chris Johnson, University of Wisconsin, Eau Claire Dennis Lang, Kansas State University Daniel Leyzberg, Princeton University Geoffrey Decker, Northern Illinois University Jeffrey A. Meunier, University of Connecticut Mark Pauley, University of Nebraska at Omaha Patricia Roth Pierce, Southern Polytechnic State University We would like to thank Park University colleagues Guillermo Tonsmann and Ken Dewey for their ongoing support. They are dedicated to providing a solid foundation to their students in terms of problem solving, object-oriented programming, and Java fundamentals, and it shows. Thanks to the students who provided feedback and searched diligently for mistakes in order to earn bonus points on their homework. In particular, thank you to Shyan Locke, Michael Dake, Marcus Shivers, Olivia Leung, Manish Lamsal, Pranoj Thapa, Peter Boyle, and Jake Thomas. Sincerely, John and Ray dea75768_fm_i-xxxviii.indd 23 4/30/20 11:55 AM
  • 19. xxiv One of the special features of this text is the diversity of its projects. Project subject matter spans six broad academic areas, as this short table shows: Abbreviation Description Easy Moderate Difficult Total CS computer science and numerical methods 15 14 6 35 Business business and accounting 11 13 3 27 Sociology social sciences and statistics 6 8 5 19 Math Phys math and physics 11 6 3 20 Engineering engineering and architecture 3 8 6 17 Biol Ecol biology and ecology 0 3 4 7 Totals 46 52 27 125 The abbreviation in the first column above will be used in a larger table below as a brief identification of a particular academic area. The four right-side columns in the above table indicate the number of proj- ects in various categories. Of course, the highest number of projects (35) occurs in the area of computer science and numerical methods. The 29 easy and moderate CS projects are typical CS introductory pro- gramming problems. The 6 difficult CS projects provide gentle introductions to some advanced topics like linked list operations, database operations, and simulated annealing. In addition, there are 27 projects in business and accounting, which include miscellaneous financial calculations, simple bookkeeping problems, and cost-accounting applications. There are 19 projects in social sciences and statistics, which include applications in sociology and political science, as well as general expe- rience. There are 20 projects in math and physics, which include applications in both classical and chaotic mechanics. There are 17 projects in engineering and architecture, which include applications in heating ventilating and air conditioning (HVAC), electrical engineering, and civil engineering. Finally, there are 7 projects in biology and ecology, which include realistic growth and predator-prey simulations. Although we’ve associated each project with one primary academic area, many of these projects can fit into other academic areas as well. Because many of these projects apply to disciplines outside the field of computer science, we do not expect that the average reader will already know about all of these “other” topics. Therefore, in our prob- lem statements, we usually take considerable time to explain the topic as well as the problem. And we often explain how to go about solving the problem—in layman’s terms. Therefore, working many of these projects will be like implementing computer solutions for customers who are not programmers themselves but understand their subject matter and know what they want you (the programmer) to do for them. They will explain their problem and how to go about solving it. But then they will expect you to create the pro- gram that actually solves that problem. Because our project explanations frequently take considerable printed space, instead of putting them in the book itself, we put them on our website: http://www.mhhe.com/dean3e The following table provides a summary of the projects on the book’s website. This table lists all of the book’s projects in a sequence that matches the book’s sequence. The first column identifies the first point Project Summary dea75768_fm_i-xxxviii.indd 24 4/30/20 11:55 AM
  • 20. Project Summary xxv at which you should be able to do the project, by chapter and section, in the form: ChapterNumber.Section- Number. The second column is a unique project number for the chapter in question. The third column identifies the project’s primary academic area with an abbreviation that’s explained in the shorter table above. The fourth column indicates the difficulty relative to where you are in your study of Java. For example, what we call “easy” involves progressively more pages of code as you progress through the book. The last two columns provide a title and brief description of each project. Project Summary Ch./Sec Proj. Academic Area Difficulty Title Brief Description 2.7 1 Business Easy Annual Bonus– (Flowchart) Draw a flowchart for an algorithm that computes an annual bonus. 2.7 2 Business Easy Annual Bonus— (Pseudocode) Write pseudocode for an algorithm that computes an annual bonus. 2.7 3 Business Easy Number of Stamps— (Flowchart) Draw a flowchart for an algorithm that calculates the number of stamps needed for an envelope. Use one stamp for every five sheets of paper. 2.7 4 Business Easy Number of Stamps— (Pseudocode) Write pseudocode for an algorithm that calculates the number of stamps needed for an envelope. Use one stamp for every five sheets of paper. 2.7 5 Biol Ecol Moderate Five Kingdoms— (Pseudocode) Write pseudocode for an algorithm that identifies a biological kingdom from a set of characteristics. 2.7 6 Math Phys Easy Speed of Sound— (Flowchart) Draw a flowchart for an algorithm that provides the speed of sound in a particular medium. 2.7 7 Math Phys Easy Speed of Sound— (Pseudocode) Write pseudocode for an algorithm that provides the speed of sound in a particular medium. 2.7 8 Business Moderate Stock Market Return— (Flowchart) Draw a flowchart for an algorithm that prints the type of market and its probability given a particular rate of return. 2.7 9 Business Moderate Stock Market Return— (Pseudocode) Write pseudocode for an algorithm that prints the type of market and its probability given a particular rate of return. 2.8 10 Business Moderate Bank Balance— (Pseudocode) Write pseudocode for an algorithm that determines the number of years until a growing bank balance reaches a million dollars. (continued) dea75768_fm_i-xxxviii.indd 25 4/30/20 11:55 AM
  • 21. Discovering Diverse Content Through Random Scribd Documents
  • 22. great sphere of activity, next to the wide field of literature, was the more modest compass of the eighteenth century salon. Madame de Lambert herself draws a parallel somewhere between the salons of the seventeenth and those of the eighteenth century, more especially with regard to the prevailing codes of morality. Her conclusions, like those of M. Brunetière nearly two centuries later, are overwhelmingly in favour of Mme de Rambouillet and her contemporaries. She complains that the delicate intellectual amusements of the seventeenth century assemblies have been largely superseded by the grosser delights of the card-table and of a declining stage. The merest semblance of knowledge is regarded with disapproval,—this in consequence of Molière's furious onslaught in his Femmes Savantes—and as a natural consequence of ignorance, the female morals have sadly decayed. Being thus deprived of the means of improving the mind, women are naturally driven to a life of pleasure-seeking. And she doubts whether society has derived any benefit from the change. Les femmes ont mis la débauche à la place du savoir, le précieux qu'on leur a tant reproché, elles l'ont changé en indécence. In other words, Mme de Lambert wanted to return to the earlier preciosity, granting women the right to be instructed, and trying to steer clear of those excesses which had called forth the attacks of Molière and Boileau. She emphatically protests against the pernicious habit of making a pleasing appearance the sole aim of female education, and claims for her sex the blessings of an education which in cultivating the mind will improve the female morals. It would be impossible to deny that the moral standard was considerably lower than it had been half a century earlier. The consequences entailed by the revocation of the Edict of Nantes and by the suppression of Port Royal had been equally disastrous. The chief bulwarks of Protestant and Catholic orthodox faith had been removed, leaving a free field to both libertinage and disbelief. The coarseness of manners which it had been the aim of the Rambouillet societies to suppress reasserted itself on the one hand, while on the
  • 23. other the rising spirit of philosophical inquiry and scientific research had degenerated into a scepticism which was no longer counteracted by that spirit of religious mysticism which had been a weapon of orthodoxy against unbelief. The Encyclopedian spirit often spelt deism and atheism, both of which flourished in the salons. The very fact that their society was no longer exclusive, but freely admitted people of all class and opinions, and from different parts of the world, accounts for the enormous influence exercised by these bureaux d'esprit upon public opinion in the eighteenth century. Moreover, the monarchical power was declining, and the king, in establishing a barrier between himself and the society of the salons, was himself instrumental in raising opinions which more and more became the prevailing ones, and upon which he had no influence whatever. Rationalism began to gain ground rapidly and became a basis for speculations which soon came to include politics and economics. M. Brunetière, whose judgment on the salons of the eighteenth century is very severe, complains that the lofty artistic and moral ideals of the preceding generation had given way to scepticism and to cynicism of a kind which made Madame de Tencin refer to her guests as ses bêtes. This statement, which no doubt is mainly correct, seems strange in consideration of the fact that it was by the new philosophy which the same salons helped in spreading, that the great problems of the future of the human race were put forward, which in broader minds gave rise to much idealism in what M. du Bled so finely calls: le souci de la modernité. But eighteenth century society regarded philosophy as an intellectual pastime rather than as bringing the hope of relief to the oppressed millions, and if it occasionally dabbled in social problems, the misery of the multitude did not touch the majority of those who lived lives of comfort and luxury, and were utterly unacquainted with suffering, very deeply. No direct attempt at improvement, therefore, was to be expected from them, they were talking in theory about things of the practice of which they knew nothing. Brunetière calls the eighteenth century salon le triomphe de l'universelle incompétence, with which its
  • 24. seventeenth century predecessor, with its more limited programme, compares favourably. It became habitual to talk wittily of serious problems, while seriously discussing trifling subjects. It needed, indeed, the fiery imagination and fervent enthusiasm of a Rousseau to inspire the philosophical theories with the life of his genius. And yet, if the social problems of the time were not directly solved by eighteenth century society, they were at least formulated by it in such a manner as to make them the catchword of the period and to draw to them the attention of those who were better able to do them justice. The very fact that the salons were ruled over by women and independent of court-influence made them the place where opinions were most freely uttered and most readily listened to. Literature, which had been the chief occupation of the early salons, now found a powerful rival in science. The poetry of the eighteenth century ruelles became of an even lighter and more insipid kind. On the other hand, the latter half of the previous century had witnessed a growing interest in anatomy and surgery, and after the introduction (by Fontenelle) of astronomy as a fashionable science, Newton became the rage, and ladies of quality like the marquise du Châtelet were among his worshippers. The domination of the salons thus became extended to philosophy, science, economics and politics. When the Ancient and Modern controversy was re- introduced in the opening years of the century, nearly all the female philosophers were fervent partisans of the Moderns, believing in a future in which all human beings would be guided by the light of Reason. Of this eighteenth century modernism, feminism is, in fact, only a subdivision. This appears from the work of Poullain de la Barre, and still more from the great defence of the Cause of Woman (when threatened by Boileau in Satire X Sur les Femmes) by the great champion of modernism Perrault in his Apologie des Femmes. The Moderns, indeed, saw in the prejudice against women a remnant of the servility of antiquity which was in flagrant contradiction with the
  • 25. dictates of Reason. Hence the close connection between feminist literature in the eighteenth century and life in the salons, of which the authors were mostly among the regular frequenters. The marquise de Lambert laid down her ideas of feminism in her Réflexions sur les Femmes, and we have seen that both D'Alembert and Marivaux were among the staunch defenders of the right of the sex to equal consideration. Boileau's death had left the précieuses in the undisputed possession of the field of light literature, to which now became added that of science. This new form of preciosity, la préciosité scientifique, which made its appearance in the salon of Mme de Lambert, where it found an ardent worshipper in Fontenelle, grew so powerful that even Voltaire's efforts to crush it with ridicule were unavailing. So strong had the female dictatorship become, that three of the most influential men-of-letters in the kingdom had vainly tried to get the better of it. But unfortunately the platonic ideal to which the women of the preceding century had owed their ascendancy had degenerated, and in consequence of the altered circumstances women often had to buy with physical submission and degradation that worship of their beauty and deference to their opinion which made them at the same time the rulers and the slaves of men, and against which the moralists of the century, with the glaring exception of Rousseau, made it their business to protest loudly, but in vain. Mme de Lambert merely wanted to restore the right sort of preciosity to its throne as an antidote to the evils of ignorance, in which she set herself the ideals of the Hôtel de Rambouillet, and advocated moderation in everything. Her salon thus became as much a protest against exaggeration and affectation as against the prevailing opinion that the education of women should only aim at teaching them how to please the opposite sex. An occasional frequenter calls it l'hôtel de Rambouillet présidé par Fontenelle, et où les précieuses corrigées se souvenaient de Molière. Being left a widow at a comparatively early age, Mme de Lambert opened her salon in the Palais Mazarin in the rue Colbert about
  • 26. 1700. She was at that time rather more than fifty, and reigned supreme over her circle of visitors for more than thirty years. She set herself to prove that it was possible to have a lively entertainment without the help of the card-table, relying chiefly on conversation and literature. Her Tuesdays and Wednesdays soon became famous, and attracted both the aristocracy and the literati. Among her regular visitors were Fontenelle, Marivaux, Mlle de Launay (Mme de Staal) and de la Motte, champion of the moderns, whilst Mme Dacier undertook the defence of the opposite cause. Mme de Lambert herself was the ruling spirit of the Académie, of which the way towards membership lay through her favour, and the chief literary productions previous to being published—if published they were— were read and criticised in her circle. If Mme de Lambert deserves mention for having kept a salon which formed a link between the seventeenth and the eighteenth century, and exercised a beneficial influence on the tone of conversation, she is even more entitled to attention on account of the part played by her in the development of feminism. She was a moralist rather than educator, and followed in the steps of Fénelon. She had the Cartesian belief in the infallibility of Reason, with two exceptions, which do honour to the qualities of her heart, and saved her from the inevitable conclusions of logic à outrance: religion and honour. Il y a deux préjugés auxquels il faut obéir: la religion et l'honneur, and a little further: En fait de religion, il faut céder aux autorités. Sur tout autre sujet, il ne faut recevoir que celle de la raison et de l'évidence, excluding even honour. But her actions show that she realised the danger which lies in obeying the duties of reason while totally excluding the admonitions of the heart. Stronger than her love of logic was that exquisite form of sensibility which made her at least a real champion of the less fortunately situated. There is real concern for the welfare of her inferiors in the precept that servants should be treated as unhappy friends, and a true love of humanity in the statement that humanity suffers in consequence of the inequality which Fortune has introduced among men. Words which come from the heart and entitle her to sympathy and admiration.
  • 27. Her ideas concerning female education are contained in the Avis d'une mère à sa fille. She insists on the importance of cultivating the female mind to render woman an agreeable companion to her husband, who will then honour her and give her her due. And she places herself on the standpoint which Mary Wollstonecraft took after her, in basing upon this foundation her vindication of women's right to be instructed. She complains of the tyranny of men, who condemn to ignorance the partners of their wedded lives, disregarding the pernicious consequences entailed thereby. For ignorance leads to vice, and the mind should be kept employed, were it only as a means of avoiding mischief. To Mme de Lambert the Muses were l'asyle des moeurs. Her educational scheme contains more instruction than Fénelon's, as it includes philosophy, which is to reclaim women to virtue through the medium of Reason. Of all the French female authors on the Woman Question it is Mme de Lambert whose ideas show the nearest approach to Mary Wollstonecraft. The essential difference between the two—the former's indifference to political emancipation—was due to a difference in social circumstances, which made her a ruler whose influence over men no political enfranchisement could have increased, and also to the condition of things in France, where the first steps towards the political equality of the stronger sex were yet to be taken. She believed the domestic circle to be the proper sphere of women, and her metaphysics of love—if less fantastic than the ideals of her 17th century predecessors, which, however, found some adherents among the regulars of her own circle in de la Motte and the Duchesse du Maine—were certainly more conducive to real happiness in the high moral principles out of which they arose. It was the marquis d'Argenson who said of her writings that they were un résumé complet de la morale du monde et du temps présent la plus parfaite, and there seems no reason to doubt the truth of his judgment. Unfortunately the good example set by the marquise de Lambert was not followed in other circles, where the increasing influence of
  • 28. the feminine element, instead of purifying the morals of the male sex, depraved them yet further. The great catastrophe of the end of the century was hastened by the vicious excesses of many females. Goncourt says that the eighteenth century lady of quality represented the principle that governed society, the reason which directed it and the voice which commanded it; she was, in fact, la cause universelle et fatale, l'origine des événements, la source des choses, and nothing could be achieved without her concurrence. Rousseau, when first arriving in Paris, was advised by a Jesuit to cultivate the acquaintance of women, for nothing ever happened in Paris except through them. The bulk of female influence upon the morals of the century was disastrous. The gross materialism amongst society-women found expression in a well-known utterance of the marquise du Châtelet: We are here merely to procure ourselves the greatest possible variety of agreeable sensations. The most perverse code of morality came to reign in some of the most-frequented salons. One of the leading hostesses of Paris boasted that one of her reception-days was reserved for gentlemen of a damaged reputation, the so- called jour des coquins. Of the Englishmen who frequented these circles of appalling vice, Horace Walpole—who in a space of forty years paid six successive visits to Paris, and who was very far indeed from being a sentimentalist,—refers to the utter absence of any sense of decency among people whose chief occupation was the demolition of all authority, whether temporal or spiritual, including the Divine Authority itself. One of the worst examples of the epicurian spirit was furnished by the salon of the notorious Mme de Tencin. She disdained even to keep up the appearance of quasi-platonic courtship and lived in open and shameless debauch. Her entire life was made up of political intrigues and adventures of gallantry, in which she turned the latter to account to promote the former. She possessed plenty of literary talent, and her two novels Le Comte de Comminges and Le siège de Calais rank among the best female productions of the century—
  • 29. but even Fontenelle thought her heartless. After a childhood spent in the very imperfect seclusion of a convent which was notorious for its nocturnal orgies, la religieuse Tencin came to Paris in 1712 to begin her siege of male hearts, directing her first attack against no less a person than the Regent himself, and ultimately contenting herself with one of his ministers, which gallant adventure was followed by many more. She gave birth to a child, whom she deposited on the steps of a church, to be found and brought up by strangers. This child afterwards became the famous d'Alembert. In order to be able to pursue her political schemes she filled her salon on different days of the week with people of various occupations and interests; keeping philosophers and académiciens, politicians and ecclesiastics carefully separated, making herself their confidante, and possessing herself of their secrets, managing them all so cleverly that they became her tools without being aware of it, secretly despising her bêtes while openly flattering them. The visitors to her two weekly dinners were nearly all men, Bolingbroke and Matthew Prior being among her habitués. Apart from Mme Geoffrin, who became her successor, and of whom she said that she only came to see if there was anything among her inventory that she might have a use for, there were hardly any women, for Mme de Tencin would brook no possible rivals. Such was her degradation that she wrote a most indecent Chronique scandaleuse for the special delectation of the Regent. As Mme de Lambert's salon represents eighteenth century society at its best, so Mme de Tencin's foreshadowed some of the worst instances of female intriguing that were to follow. A totally different salon was that kept by Mme Geoffrin. Mme de Tencin—whose own birth was not above suspicion—had all the pride of class, and looked down upon the Third Estate; Mme Geoffrin on the contrary was the daughter of a court-valet and consequently remained all her life a bourgeoise, without any pretence to préciosité or anything but a kind and warm heart, a most remarkable wit, sound common sense and a natural delicacy which
  • 30. made her an ideal hostess. For Mme de Tencin's lofty disdain she substituted an almost maternal solicitude for the welfare of her children, who, with the exception of Mlle de Lespinasse, were of the male sex. Besides d'Alembert, Diderot, Morellet and Grimm there were the ubiquitous Horace Walpole, David Hume the philosopher and Wraxall; the first-named of whom in his correspondence declared her to be a most extraordinary woman with more common sense than he had ever encountered in one of her sex. The principles of the salon in the Rue St. Honoré were much the same as at Mme de Tencin's, but a milder spirit prevailed, and the demon of intrigue was absent. Mme Geoffrin kept fixed reception- days, her Mondays being devoted to artists, and her Wednesdays to men-of-letters and philosophers, while her intimates were made welcome on both days. The hostess presided over the assemblies without in any way obtruding her personal opinions or bringing her private interests into play, exercising an absolute authority which never became tyranny, and keeping peace among the more excitable of her guests[12]. She was much appreciated by them all, not least by the future king of Poland, Stanislas Augustus, her devoted son, causing Walpole to refer to her as the queen-mother of Poland. Her apotheosis came when in her sixty-eighth year she visited Warsaw, where she met with a royal reception. After her return her mental powers declined rapidly, and her daughter—fearing the influence of scepticism upon her mother—kept her favourite philosophers at a distance, eliciting from her the remark that she was, like Godfrey of Bouillon, protecting her tomb against the infidels. The third of the Muses of the philosophical Decameron, whose salon was much in vogue, was Julie de Lespinasse, whose attractive personality and brilliant conversational and epistolary powers account for her success. She combined the warmth of heart of Mme Geoffrin with the ardent temperament of Mme de Tencin, but without the latter's brazen-facedness. She possessed a degree of sensibility which made her succumb to different lovers for each of
  • 31. whom she cherished a passion which it was beyond her power to resist. Her youth had been fed with Richardson, Clarissa Harlowe being her favourite. She had entered the employ of the famous marquise du Deffand, herself a prominent hostess, in the capacity of reader. Her wit and the natural buoyancy of her character soon made her more popular than her mistress, whose guests took to visiting her in her room, while her mistress was still asleep. Mme du Deffand in her jealousy accused her of skimming off the cream of her visitors' conversation; a breach followed, and Julie was enabled by some supporters to set up a small salon in the rue St. Dominique, which flourished from 1764 till the year of her death in 1776. She could not afford sumptuous dinners, but her guests were sure of a warm welcome and of some interesting conversation, which she conducted so tactfully, effacing herself completely and making her guests feel at home by always appearing interested, that her lack of personal beauty was quite forgotten in the charm of her manner. Politics were a frequent topic, and Mlle de Lespinasse was among the professed admirers of the British Constitution. D'Alembert, Condorcet, Turgot and also Mme Geoffrin belonged to her circle, and that Walpole knew her also, appears from the correspondence between him and Mme du Deffand, who at Julie's death complained that the rupture with her had robbed her of the friendship of d'Alembert. While the women of society were celebrating their triumphs in the salons, philosophy was trying to do something for the female multitude. We have seen that it was Fénelon who caused education to be included among the subjects of moral philosophy, but it was the diffusive power of Rousseau's writings that made it one of the most frequently discussed themes of the century. His Emile, ou de l'Education, which appeared in 1762—curiously enough, the year of the suppression of Jesuitism in France—marked a new era in the history of education, if not in that of feminism. Of Rousseau it might have been reasonably expected as the champion of liberty and equality to carry to their full extent the philosophical venturings of Fénelon and thus to usher in a new era of female emancipation.
  • 32. However, with an inconsistency which is one of his chief characteristics, Rousseau not only deliberately left the female half of mankind out of his scheme for political enfranchisement, but ranged himself among the anti-feminists by the great emphasis he laid on the consideration of a sexual character, which he construed into evidence of female inferiority, by arguing that it makes the subjection of woman a natural law, which is to be respected according to the theory that whatever is in Nature, must be right. Owing to the contradictory nature of his views, however, while directly opposing the movement, he indirectly furthered it in two ways. In the first place, his social theories were adopted without reserve and without restrictions by some of his followers, who thus repaired the omission which had left Woman out of the scheme; and secondly it was Rousseau who once for all broke the back of the monastic system of education by continuing the campaign which Fénelon in theory, and Mme de Maintenon in practice, had entered upon before him, and bringing it to a happy conclusion. The reduction and ultimate abolition of the education of religion, which was one of the great victories of the philosophical school, became manifest in the latter half of the century. It was a signal success, achieved over an unwilling government and crowned by the expulsion of the Jesuits, who had formed one of the chief bulwarks against the growing revolutionary spirit. The Cartesian principles, which had been a beacon-light to seventeenth century philosophy, were supplemented in the next by a new element: that of utility. In John Locke's Treatises of Government and also in Some Thoughts concerning Education, he let himself be guided chiefly by considerations of usefulness, thus becoming the founder of that doctrine of Utilitarianism which, after influencing the French Encyclopedians, was to return to England a century later and to find a fervent champion in William Godwin. In deciding upon a course of action, the inevitable question was: What is the use? and this guiding principle became paramount also in matters of education. To Locke, who was a man of practical sense and not a mere theorist, the problem was how to make people
  • 33. understand their real interests, and to make them act in accordance with them, which must necessarily lead to happiness. His educational system, therefore, is based upon the communication of such useful knowledge as will most contribute to the total amount of happiness to be found on this globe[13]. Locke insisted on the necessity for a physical education which increases the mental and moral capacity by rendering the body less subject to fatigue. Simplicity and effectiveness in dress and food, and plenty of outdoor exercise are recommended, and in this important matter, as indeed in a great many others, Locke may be said to have struck the keynote of the philosophical tendencies of the eighteenth century, anticipating the famous Nature-theory of Rousseau. Many important questions were mooted by him. He introduced the ethical problem of reward and punishment, and discussed the advisability of reasoning with a child and of making him learn a trade, which became a part of the educational programme of the next generations. The French philosophers became Locke's immediate heirs, and afterwards repaid their debt to England with interest. Where Locke gave his young gentleman a tutor, his views were adopted by the opponents of the monastic education. It could hardly be expected of Locke, who lived in a time when the female fortunes in his own country were at a very low ebb, to have paid much attention to the possibility of making women share in the obvious advantages of the new system. However, if he did little or nothing for British women, his theories were turned to account for the benefit of their French sisters, whose position in the lower walks of life was not very much better than theirs. His French disciples, carrying the theory of utility to its fullest extent, included the female sex in their reflections. The first in point of time was the Abbé de St. Pierre, of whom Rousseau contemptuously said that he was a man of great schemes and narrow views. Seen from a feminist standpoint this judgment is cruelly unjust. For, even granting that the Abbé's schemes were too Utopian to be capable of full realisation—a circumstance he himself sadly recognised—the fact remains that he was responsible for the first project of female education on a national basis, making
  • 34. wholesale education a state-concern and thus wanting to extend the benefit of instruction to many who would otherwise be deprived of it. He stands at the beginning of the lane that leads via Bernardin de St. Pierre and Talleyrand to the great Condorcet. The Abbé de St. Pierre was willing to grant women as a class that equality which the better-class women had actually attained, and he believed in their instruction, holding that on the instruction given to the young, whether male or female, depended the happiness of the coming race. But he believed still more in the necessity for a moral education, for his utilitarianism is not of this earth, but of eternity. With him the ever recurring question is: What will it profit the soul?, and the fear of punishment in Hell is rather stronger with him than the sense of moral duty. He thus laid himself open to attack from the notorious Mme de Puysieux, who believed in reputation and the preservation of appearances, informing him that it was silly to let the fear of Hell withhold people from seeking happiness by cultivating the good opinion of others, whether deserved or not! The final clause sums up what moralists found most objectionable in the inclinations of a depraved age. The real aim of women, according to the Abbé, should be to please God, and not men, so as to gain eternal life. He has no ambition for women beyond that of making them devout Christians and good housekeepers, and his educational efforts are accordingly directed towards these two accomplishments. Girls are to dress simply, to eschew cards—that curse of the age—and to learn useful needlework, the keeping of accounts and in general such things as will be of the greatest use to them in the performance of their domestic duties. But he very unaccountably refuses their youth the advantages and innocent enjoyments of home-life, wishing them to be brought up in colleges, in which they are to be kept immured until such time as their education will be completed, when they will be ready for matrimony! At college girls may learn to be good citizenesses, but they will scarcely gain the necessary experience for managing a home of their own. The comprehensiveness of his
  • 35. scheme, however, and his recognition of the female equality entitles him to a place in the history of feminism above Rousseau. The latter's attitude towards the feminist movement is so complicated as to demand careful analysis. Where women were concerned the strong individuality of the female genius would not allow him to side fully either with those who wished to condemn them to a life of household-drudgery, making of them a sort of superior slaves, or those who, not satisfied to vindicate woman's rights, made her usurp those of the stronger sex, for the former have too low a notion of the duties of womanhood, whilst the latter overlook the considerations of a sexual character by which, according to Rousseau, the relations between the sexes are exclusively determined. Rousseau's opinion of the depth to which women had sunk appears from his Lettre à d'Alembert sur les Spectacles, which contains a fierce onslaught upon their moral perversity, which has caused the drama, too feeble to rise to worthier themes, to fall back upon erotics of a most despicable kind. Rousseau judged women capable of becoming something better than what eighteenth century society had made of them, but in his demands for them and in his schemes for perfecting their moral education he was extremely modest. Next to the salons he held the education of the convents, ces véritables écoles de coquetterie, to be chiefly responsible for the degradation of the female character. The young women who, on leaving them, enter society, carry into instant practice the lessons of vanity and coquetry which the convents have supplied. For convent and salon Rousseau wanted to substitute the blessings of true domesticity—painted in glowing colours in the pages of the Nouvelle Héloise. His sympathies went out, not to that college-life of which the Abbé de St. Pierre had such sanguine expectations, but to the intimacies of the family-circle, presided over by loving parents, an ideal which he reintroduced in the fifth book of his treatise on education, where, circumstances rendering it advisable to provide the finished male product with a suitable partner for life, the principles of Sophie's education are elaborately described[14].
  • 36. Where he recommends making the duties of life as pleasant as possible to the young pupil, protesting against that austere conception which allowed her no other diversion than studies and prayers, Rousseau sides with Fénelon. In his opinion girls enjoy too little freedom, whilst grown-up women are left too much liberty. Let the young girls have an opportunity to enjoy life, he says, or they will take it when they are older. Nor does the notion of making them at an early age acquainted with the world inspire him with terror, for he trusts with Mme de Sévigné that the sight of noisy gatherings will only fill them with disgust instead of tempting them to imitation. So far there is nothing anti-feminist in Rousseau's ideas. But unfortunately we have come to the end of what is positive and his further utterances rather advocate woman's subjection than her enfranchisement. The habit of reverting to first principles which is so dominant a characteristic of his Nature-theory makes him draw a parallel between the sexes upon the foundation of those innate qualities which constitute the sexual character. Men and women are the same in whatever is independent of sex, and radically different, almost diametrically opposed, in all that pertains to it. Thus all disputes regarding equality are vain, for in what the sexes have in common they are naturally equal, and in that in which they differ no comparison is possible. And woman is to be congratulated upon this diversity, for in it lies the great secret of her subtle power. Where woman asserts the natural rights which arise from this difference she is superior to man; where she tries to usurp the natural rights of the opposite sex she remains hopelessly below their level. The two sexes have different spheres of activity, and each sex can do well only in its own sharply-defined sphere. Reason itself demands this stress laid on the contrast between the sexes. For, says Rousseau, once women are brought up to be as like men as possible, their authority and influence, which are rooted in their being essentially different, will be lost without a substitute. This remark is one of great wisdom and psychological insight. Rousseau saw what many extreme feminists are so apt to forget, that those
  • 37. who wish to develop in women those qualities which naturally belong to man, and to suppress in them what is proper to their own sex, are in reality doing them irreparable harm. There are, according to Rousseau, a male empire and a female one. The former rests upon a foundation of superior physical strength and mental superiority; but although the stronger sex are masters in appearance, they in reality depend on the weaker. For the female empire, established by Nature herself, derives its strength from those delicate feminine charms which command the worship of that gallantry which Nature again has instilled into the hearts of men. In giving this interpretation of female power and influence Rousseau exposed himself to attack. The platonic worship, we have seen, had sadly degenerated, and what remained was a worthless, hypocritical imitation which was felt by well-meaning women as an insult rather than a compliment. But what called down a storm of feminist indignation upon his head was the sweeping conclusion he drew from the natural law that man, having physical strength on his side, must always play the active part in the intercourse between people of different sexes, while woman has to be always content with the passive rôle. The sole object of women, says Rousseau, ought consequently to be to please men, on whom their relative weakness has made them dependent, and goes on to assert that all female education should as a natural consequence be relative to men. There is in the above passage, which shows that on the subject of feminism Rousseau, instead of a revolutionary, was rather a conservative, nothing to suggest the bold and daring vindication of female rights that was so soon to resound in the philosophical world like a mighty trumpet-blast. His ideas about the position of Woman are characteristic of his want of equilibrium in presenting a bewildering chaos of judicious observations and unaccountable oversights. It is not so much that some of his statements are untrue, as that they are incomplete. In drawing sweeping conclusions from the physical inferiority of the sex he deliberately closes his eyes to their moral and mental possibilities. It is true that he insists upon a
  • 38. moral education for women, but whatever of merit may be contained in this claim is instantly neutralised by its only object: making women more acceptable companions to their husbands, contributing to the happiness of the latter by unwearying devotion and unalterable constancy. There are undoubtedly many women to whom the above would seem the most acceptable task, as there are others whose consciousness of their talents would make them indignantly reject so subordinate a part. As long as women are not cut after the same pattern, allowance will have to be made for individual propensities and any theory, however cleverly put together, will succeed with some types of womanhood and hopelessly fail with others. St. Marc Girardin indignantly remarks that the condition of the women in Rousseau's Nature-scheme suggests the oriental seraglio. This is an exaggeration, for the relative education is qualified by Rousseau to such an extent that the harem-picture which it may at first conjure up is considerably modified. He wished the term made to please men to be understood in a far wider meaning than the merely sensual, for no one realised better than he that in the absence of a spiritual element no love based upon the grosser passions can possibly endure. Where the female weaknesses and vanities are concerned Rousseau's discernment even surpasses that of Fénelon. The task of woman being to please, Nature has made her regard above all things the opinion of the opposite sex. And the moralist who teaches men to ignore the opinion of others as destructive of individuality, goes so far as to prescribe for women an unlimited deference to opinion and reputation. Opinion, which is the grave of virtue among men, ought to be among women its high throne. The utilitarian question: A quoi cela est-il bon?, which is to be the guiding principle in Emile's case, changes its character where Sophie is concerned, and becomes: Quel effet cela fera-t-il? The question what impression a thing will produce naturally leads to putting the
  • 39. shadow before the substance, and appearance before reality, and as such may have a most disastrous effect. Sophie's love of needlework is accounted for not so much by considerations of usefulness as by the reflection that this delicate occupation will make her appear to advantage to her admirer. The same train of thoughts makes her abominate the useful occupation of cooking, by which her hands might become soiled. Did Rousseau actually imagine that his much-recommended simplicity in dress would hold out against the innate love of finery which was to help in the accomplishment of what he considered the chief aim of womanhood? Rousseau certainly did not mean to imply that woman must of necessity be morally inferior to man, but simply that Nature had ordained that she shall be subjected to his superior strength, to his cooler judgment and to his superior common sense. He was certainly capable of imagining an ideal female, and of worshipping in her the essentially sexual qualities which make her differ from man. That portion of the fifth book of Emile which deals with the first meeting between the lovers leaves little doubt as to how he pictured to himself his ideal of womanhood. The philosophical treatise is more than once in danger of becoming a romance, embodying the slightly sobered ideals of courtship of the author of Julie. It cannot be denied that Sophie has charm and that her subjection to Emile is not oppressive. But to form a correct notion of Rousseau's ideas regarding the social position of women we must strip the story of its lyrical element and glance at the purely philosophical portion of the treatise. It is there that we must look for an answer to the question: Did Rousseau look upon women as partakers of the faculty of Reason? And he gives his reply in the following words: L'art de penser n'est pas étranger aux femmes, mais elles ne doivent faire qu'effleurer les sciences de raisonnement. He would not even object to a system by which the functions of women were strictly limited to the performance of sexual duties, if it were not that utter ignorance would make them fall a too easy prey to rascally adventurers! The
  • 40. subsequent statement that, after all, it being the task of woman to get herself esteemed, so as to justify her husband's choice, a little knowledge would not come amiss, does not mend matters in its re- introduction of the relativity-principle. Here indeed, Rousseau pitches the pipe too low. Woman's special domain is that of sentiment. But the very sensibility which renders her more alluring by contrast, prevents her from forming a sound judgment. This appreciation of women appears clearly in the passages of Emile in which the choice of a religion is discussed. Emile is not allowed to decide until he has completed his eighteenth year, when he is made to judge for himself, uninfluenced by his tutor. Sophie's religious notions, on the contrary, are carefully instilled by her parents at an early age, it being silently taken for granted that she will never arrive at a degree of understanding which will enable her to form her own convictions. The female reason is of a practical nature, which renders them very quick to find the means of arriving at a fixed conclusion, but does not enable them to form that conclusion independently of others. Again that utter dependence, that total lack of individuality which characterises Rousseau's female ideal. My daughter, says Sophie's father, knowledge does not belong to your age; when the time has come, your husband will instruct you. The amount of actual instruction in Rousseau's scheme is reduced to a minimum. There is no knowing what damage may be done to the unstable female imagination by the dangerous literature of the time. Here we recognise the author of the Dijon prize-essay with its crushing conclusion. Rousseau frankly hated the femme bel esprit. Sophie's mind is to be formed by observation and reflection, and not by books. But how can Sophie be supposed to reflect, one might ask, unless she had certain fundamental truths pointed out to her, the instilment of which is not the work of every parent, however well-intentioned? It is Rousseau's fatal mistake that he cannot bring himself to realise that moral culture simply cannot exist without a certain amount of intellectual culture. He wanted to have both
  • 41. granted to men, and his conclusions tended to withhold both from women. The march of humanity finds him in the first rank of those who were pioneers; the feminist movement, while recognising his cleverness, looks upon him as a dangerous, and sometimes does him the injustice of calling him an hypocritical enemy. The charge of insincerity has, indeed, been often brought against him, although he has found some defenders also. However, he is condemned by most women. Mrs. Fawcett, in her introduction to Mary Wollstonecraft's Vindication, opines that a man who made so light of his duties towards his own children, and whose married life was so full of blame has no right to pronounce on problems which require the disinterestedness and self-abnegation of the pure idealist. Where Rousseau points out the shortcomings of the women, of his time and regrets them, he is with Mary Wollstonecraft; where he fails to show the way by which improvement may be attained, he remains hopelessly behind one who, with considerably less genius, had a great deal more moral courage and a far wider conception of the ideals of woman. Of the disciples and opponents of Rousseau, some of whom, like Mme de Staël, Mme de Genlis, and Mme de Necker de Saussure were of the female sex, little need be said here, as their writings either did not throw any new light on the problem under consideration, or belong to a period following that of Mary Wollstonecraft. When the Revolution came, bringing with it an increased demand for a public education, some of its theorists, who like Condorcet, showed an interest in the female part of the problem, will call for mention.
  • 42. FOOTNOTES: [10] The Revue d'Histoire Littéraire de la France (Tome XXIII, XXIV and XXV) contains a contribution by M. Raymond Toinet entitled: Les Ecrivains moralistes au 17ième siècle; being an alphabetical nomenclature of moral writings published during the age of Louis the Fourteenth (1638-1715). In this list works of a feminist or an anti- feminist nature figure so largely that little doubt can be entertained as to the interest taken in the topic under discussion. They may be conveniently classified as follows: 1. Assertions of female superiority, including a. o. two French translations of Agrippa, three pieces entitled: Le Triomphe des Dames, and one by Mlle. Jacquette Guillaume, entitled: Les Dames Illustres. They were frequently combined with attacks on the male half of humanity, as in the case of Regnard's Satire contre les Maris. 2. Apologies for the female sex, including Perrault's Apologie des Femmes, Poullain de la Barre's Egalité des deux Sexes, and a Latin translation of Anna Maria Schuurman. Some were meant as a refutation of some male attack. To this class belong Ninon de l'Enclos' Coquette Vengee and a number of replies to Boileau's satire. 3. Attacks on the female sex, which are gradually diminishing in number, or rather changing from the direct invective to the moral essay with a didactic purpose, busying itself with the female morals and the female character. A collection of pieces dealing with the problem of sexual preference was published in 1698 by de Vertron under the name of La nouvelle Pandore, ou les femmes illustres du siècle de Louis le Grand. 4. Rules of female conduct, for the use of young ladies about to enter the world, insisting chiefly on the feminine duty of
  • 43. preserving the reputation. A translation of Lord Halifax's Advice (see page 83), Etrennes ou conseils d'un homme de qualité à sa fille seems to have attracted some notice. 5. Pieces dealing with the relations between the sexes in daily intercourse, including the subjects of love and gallantry, and of marriage. Some are directly favourable to the state of matrimony, pointing to the reciprocal duties of the partners in the contract, and instructing them in the readiest way to happiness; others, frequently deriving their inspiration from Boileau, arguing about marriage as a social institution and enumerating its advantages and its drawbacks. To the period under discussion belongs a translation of Erasmus' Christian Marriage. 6. Treatises of female education, containing a plea for the development of the female intellect. They are, as yet, remarkably few. Beyond the contributions by Poullain de la Barre and Fénelon there are some half-dozen pieces dealing with the education of girls on a religious basis, and a few in which the question of the pursuit of science and philosophy by women is stated and answered favourably. There was an Apologie de la science des Dames, par Cléante, (1662); a treatise entitled: Avantages que les femmes peuvent recevoir de la philosophie et principalement de la morale, (1667); another by René Bary bearing the somewhat questionable title of La fine philosophie accommodée à l'intelligence des dames, and, in conclusion, one by Guillaume Colletet, headed: Question célèbre, s'il est nécessaire ou non que les filles soient savantes, agitée de part et d'autre par Mlle Anne Marie de Schurmann, hollandoise, et André Rivet, poictevin, le tout mis en françois par le sieur Colletet (1646). [11] La Nouvelle Colonie, ou la Ligue des Femmes, first presented in the Théâtre italien on the 18th of April 1729, a three-act comedy, afterwards reduced to one single act to be performed in the
  • 44. théâtres de société, and published in this form in the Mercure. (Cf. Larroumet; Marivaux, sa Vie et ses Oeuvres, Paris 1882). [12] Such, at least, is the description of Mme Geoffrin's character in M. E. Pilon's Portraits français. M. G. Lanson, in his Lettres du dix- huitième siècle, accuses her of vanity and consequent despotic leanings. Elle aimait à conseiller ses amis, et les régentait en mère un peu despotique; elle n'aimait pas les indépendants, les âmes indociles et fières qui ne se laissent pas protéger, et veulent être consultés dans le bien qu'on leur fait. [13] That a great many of the Utilitarian ideas of John Locke may be traced to their origin in the works of Montaigne has been demonstrated by M. Pierre Villey in his L'influence de Montaigne sur les Idées pédagogiques de Locke et de Rousseau, who thus claims for the literature of his own country an honour which was commonly granted to that of England. [14] The education recommended for Emile is not domestic. He was to be kept carefully isolated from the world, so as to escape its taint, until such time as his character would be fully matured, placing him above the reach of disastrous influences. A similar principle had prevailed at Mme de Maintenon's establishment of St. Cyr.
  • 45. CHAPTER IV. Feminist and Anti-Feminist Tendencies among the English Augustans. In studying the march of feminism among the two rival nations on either side the Channel, one cannot help being struck by the remarkable lateness of anything resembling a feminist movement in England. That the women of mediaeval England were looked down upon, not only on account of their inferior muscular strength, but also on the score of their supposed want of mental and moral stability, appears but too plainly from the numerous scornful references to the weaker sex in the literature of those days. The Song-collections of the Transition Period clearly betray the esprit gaulois in their brutal estimate of woman and in the tone of undisguised contempt and ridicule which prevails whenever women are the theme. The often-repeated story of the henpecked husband and the shrewish wife contains a warning against marriage which, although couched in the form of banter, evidently has its foundation in the general conviction of female depravity. The early plays with their brawling scenes and stock female characters were also most unfavourable to women. Nor did the early Renaissance bring any marked improvement either in the female morals or in the male appreciation of them, for the satires against women continued with hardly a refutation. The improvement which resulted in Ascham's days from the awakening female interest in learning and in the Caroline period from the introduction into poetry of the Platonic love ideal, was too partial and too qualified to be permanent, and in later years the Puritanic ideal of womanhood was an abomination to feminists of the Wollstonecraft type. But the general estimate of women in England had never been lower than in the notorious days that followed the Restoration. In the Middle Ages all influence had been denied them on the score of their supposed inferiority of
  • 46. 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. Let us accompany you on the journey of exploring knowledge and personal growth! ebookluna.com