SlideShare a Scribd company logo
1 of 97
Barrons
Exam pattern
• Duration : 3 hrs
• No books, calculator, Computers are allowed
• Section 1
• 40 MCQ – 1 hr 30 mins
• Scored by Machine
• No negative marks
• Section 2
• 4 Free response questions - 1hr 30mins
• Scored by Human readers
Tips for taking exam
Introductory Java Language Features
• Packages and classes
• Input/Output
• Types of identifiers
• Operators
• Control Structures
• Errors and exceptions
Package and classess
• Java.util
• Java.lang
• Import
Types and Identifiers
• Identifier
• Name for variable, method, parameter,class etc
• Sequeuce of letters, digit and underscore
• Java Nameing converstion
• Types
• Int
• Double
• Boolean
Not tested in AP
• Char
• Base 2, base 8 base 16
Final variable
• Usually in upper case
• final int CLASS_SIZE=35
• Final with if condition
Operators
• Arithmetic Operators
• Relational Operators
• Logical Operators
• Relational operators
• Increment and decrement
Arithmetic Operators
• +
• -
• *
• /
• %
Precedence
• Parentheses
• */%
• +-
• Left to right
Relational Operators
• ==
• !=
• >
• <
• >=
• <=
• Evaualte to true or false
Logical Operators
• Boolean operator
• !
• &&
• ||
• Based on truth tbale of logical opeartors
Assignment Operators
• =
• +=
• -+
• *=
• /=
• %=
Increment and decrement
• ++
• --
Operator Precedence
! ++ --
* / %
+ -
< > <= >=
== !=
&&
||
= += -= *= /= %=
Input output
• Scanner class (not tested in AP)
• System.out.println
• System.out.print
Escape Sequene
• n
• ”
•
Control Structures
• Decession making
• Iteration
Decision Making
• If
• If else
• Switch(not part of AP)
• Nested if
• Extened if (if else lader)
Iteration
• For
• While
• Do-while(Not a part of AP)
For loop
• Syntax
• (for i=0;i<5;i++)
• {
• Statements
• }
Enhanced for loop (for each loop)
• Synatax
• For(eleemt:collections)
• {
• }
While loop
• Syntax
• While (boolena test)
• {
• satements
• }
Nested Loop
• Loop inside another loop
Errors and Exceptions
• Exceptions
• During the execution
• / by zero
• Unchecked Exceptions
• Arithmetic Exceptions
• Null pointer
• Array index out of bounds
• Index out of bounds
• Stringindexoutof bound
• Concurrent modifications
• Checked exceptions (Not AP syllabus)
Class and Object
• Objects
• Classess
• Private public static
• Methods
• Scope
• references
Objects
• Real time entities
• State / data members / properties
• Behaviour/methods/functions
Class
• Blue print or template
• Single instance of class
• Data encapsulation
• Combining object data and methods into single unit
Private, public,static
• Public (all classes are publc in AP )
• Private
• Only within in class (all the instansce variable are private in AP)
• Static
• Class level variables
• Memory allocated only once
Static final
Methods
• Headers
• Public void withdraw (String password)
• Types of Methods
• Constructors
• No argument constroutros
• Parameter construtors
• Accessors
• Getters
• Mutators
• setters
• Static methods
Method overloading
• Two or more methods in same calss with same and different
parameters
Scope
• Variable or method is visible
• Local variable
• block
This keyword
• Always called for particular object
References
• Object and Arrays
• Reference vs primitive types
• Null reference
Method Parameters
• Formal parameters
• Actual parameters
• Primitive type as parameter
• Local to the method any changes made will not reflect in calling program
• Object as parameter
• Local to the method any changes made will not reflect in calling program
Inheritance and polymorphism
• Inheritance
• Polymorphism
• Type compatability
Inheritance
• Super calss
• Sub calss
• Code reuse
Inheritance Hierarchy
• Person
• Student Employee
• Grad student under grade
• Is a relationship
Implementing Subclass
• Extends keyword
• Inherting methods and variables
• Private
• Public
• Protected (Not part of AP)
Method Overridding
• Defining method with same same retrun type and signature
• Super keyword
Constructor and super
• Construtor never inherited
Declaraing Subclass Object
Polymorphism
• Many forms
Dynamic Binding(Late Binding)
Type Compatibility
• Downcasting
Not in AP
• Abstract calss
• Interface
Standard classes
• Object
• String
• Wrapper
• Math
Object class
• Universal supperclass
• Methods
• toString
• equals
String Class
• Immutable
• Concatenation
• Equals
• Compare TO
• Length()
• Substring
• indexOf
Wrapper Class
• Integer class
• Double class
Integer
• Integer(int value)
• intValue()
• Integer.MIN_Value
• Integer.MAX_VALUE
Double Class
• Double(double value) - Boxing
• doubleValue() - Unboxing
Autoboxing and Unboxing
• Autoboxing – primitive to wrapper type
• Unboxing – wrapper to primitive type
Comparission of Wrapper calss object
Math Class
• Standard mathematical functions
• Abs
• Pow
• Sqrt
• random
Random
Program design and analysis
• Software development
• Object oriented program design
• Program analysis
Software Development
• Program Specification
• Program Design
• Program implementation
• Testing and debugging
• Type of errors
• Robustness
• Program maintenance
Object Oriented program design
• Identifing class
• Iddntifing behaviours
• Determingn relationship between classes
• UML Diagrams
• Implemeenting classes
• Buttom up
• Top down
• Implemeenting methods
• Procedureal abstraction
• Data Encapsulation
• Stub method
Algorithm
Program Analysis
• Program correctness
• Assertions
• Pre conditions
• Post condtions
• Efficiency
• CPU time
• Memory
Arrays and ArrayList
• One Dimension array
• ArrayList
• Two dimension arry
1d array
• Same type
• Initilization
• Length
• Traversing
• For loop
• Enhanced for loop
Arrays as parameters
Shuffling
Array Variable in class
Array of class objects
Analysing Array algorthims
ArrayList
ArrayList Class
• Java.util package
• ArrayList<E>
Methods
• ArrayList()
• Int size()
• Add()
• Get()
• Set()
• Remove()
Autoboxing and unboxing
Not part of AP
• List<E> interface
• Methods of List<E>
Traversing arraylist
Random element selection
Two dimension array
• Board games, matrix,table, mazes
• Declaration
Matrix as array of rows
Processing a two –dimension array
Two D array as a parameter
Mirror images
Recursion
• Recursive methods
• General form of simple recursive methods
• Writing recursive methods
• Analsyis ofrecursive methods
• Recursive helper methods
• Recursion in two d girds
Recursive methods
• Method calls itself
General form of Simple recrusive methods
Writing recursive methods
Analysis of recursive methods
Recrusive helper methods
Recursion in two d grids
Sort and searching
• Selection and insertions sort
• Merge and quick sort
• Sorting algorithm injava
• Sequentials serach
• Binary serach
Selection sort
Insertion sort
Merge sort
Quick sort
Sorting algo in java
Sequential serach
Binary serach
Analysis of binary search

More Related Content

Similar to AP computer barron book ppt AP CS A.pptx

Unit Testing Done Right
Unit Testing Done RightUnit Testing Done Right
Unit Testing Done RightBrian Fenton
 
Learning core java
Learning core javaLearning core java
Learning core javaAbhay Bharti
 
Python-Magnitia-ToC.pdf
Python-Magnitia-ToC.pdfPython-Magnitia-ToC.pdf
Python-Magnitia-ToC.pdfAnanthReddy38
 
What's new in Java 8
What's new in Java 8What's new in Java 8
What's new in Java 8Kyle Smith
 
Week 2: Getting Your Hands Dirty – Part 2
Week 2: Getting Your Hands Dirty – Part 2Week 2: Getting Your Hands Dirty – Part 2
Week 2: Getting Your Hands Dirty – Part 2Jamshid Hashimi
 
Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad Sathya Technologies
 
Testing Tools course training institute Hyderabad
Testing Tools course training institute HyderabadTesting Tools course training institute Hyderabad
Testing Tools course training institute HyderabadJaya Suresh Nunna
 
Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad Sathya Technologies
 
Testing Tools course training institute hyderabad
Testing Tools course training institute hyderabadTesting Tools course training institute hyderabad
Testing Tools course training institute hyderabadJaya Suresh Nunna
 
Creativity and Curiosity - The Trial and Error of Data Science
Creativity and Curiosity - The Trial and Error of Data ScienceCreativity and Curiosity - The Trial and Error of Data Science
Creativity and Curiosity - The Trial and Error of Data ScienceDamianMingle
 
Rapid Application Development using Ruby on Rails
Rapid Application Development using Ruby on RailsRapid Application Development using Ruby on Rails
Rapid Application Development using Ruby on RailsSimobo
 
Indic threads pune12-typesafe stack software development on the jvm
Indic threads pune12-typesafe stack software development on the jvmIndic threads pune12-typesafe stack software development on the jvm
Indic threads pune12-typesafe stack software development on the jvmIndicThreads
 
Apache Spark Machine Learning
Apache Spark Machine LearningApache Spark Machine Learning
Apache Spark Machine LearningPraveen Devarao
 
Programming in java basics
Programming in java  basicsProgramming in java  basics
Programming in java basicsLovelitJose
 

Similar to AP computer barron book ppt AP CS A.pptx (20)

Unit Testing Done Right
Unit Testing Done RightUnit Testing Done Right
Unit Testing Done Right
 
Clean Code
Clean CodeClean Code
Clean Code
 
Learning core java
Learning core javaLearning core java
Learning core java
 
Python-Magnitia-ToC.pdf
Python-Magnitia-ToC.pdfPython-Magnitia-ToC.pdf
Python-Magnitia-ToC.pdf
 
Apache Spark MLlib
Apache Spark MLlib Apache Spark MLlib
Apache Spark MLlib
 
VB.net&OOP.pptx
VB.net&OOP.pptxVB.net&OOP.pptx
VB.net&OOP.pptx
 
What's new in Java 8
What's new in Java 8What's new in Java 8
What's new in Java 8
 
Php Online Training
Php Online TrainingPhp Online Training
Php Online Training
 
Week 2: Getting Your Hands Dirty – Part 2
Week 2: Getting Your Hands Dirty – Part 2Week 2: Getting Your Hands Dirty – Part 2
Week 2: Getting Your Hands Dirty – Part 2
 
Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad
 
Testing Tools course training institute Hyderabad
Testing Tools course training institute HyderabadTesting Tools course training institute Hyderabad
Testing Tools course training institute Hyderabad
 
Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad Testing Tools course training institute ameerpet hyderabad
Testing Tools course training institute ameerpet hyderabad
 
Testing Tools course training institute hyderabad
Testing Tools course training institute hyderabadTesting Tools course training institute hyderabad
Testing Tools course training institute hyderabad
 
Creativity and Curiosity - The Trial and Error of Data Science
Creativity and Curiosity - The Trial and Error of Data ScienceCreativity and Curiosity - The Trial and Error of Data Science
Creativity and Curiosity - The Trial and Error of Data Science
 
Rapid Application Development using Ruby on Rails
Rapid Application Development using Ruby on RailsRapid Application Development using Ruby on Rails
Rapid Application Development using Ruby on Rails
 
Indic threads pune12-typesafe stack software development on the jvm
Indic threads pune12-typesafe stack software development on the jvmIndic threads pune12-typesafe stack software development on the jvm
Indic threads pune12-typesafe stack software development on the jvm
 
Apache Spark Machine Learning
Apache Spark Machine LearningApache Spark Machine Learning
Apache Spark Machine Learning
 
Python
PythonPython
Python
 
Programming in java basics
Programming in java  basicsProgramming in java  basics
Programming in java basics
 
Ajax
AjaxAjax
Ajax
 

Recently uploaded

How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17Celine George
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphThiyagu K
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Shubhangi Sonawane
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsTechSoup
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxVishalSingh1417
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxAreebaZafar22
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfAyushMahapatra5
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAssociation for Project Management
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfAdmir Softic
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingTeacherCyreneCayanan
 

Recently uploaded (20)

How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptx
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdf
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writing
 

AP computer barron book ppt AP CS A.pptx