Java Programming Review 1

Slides:



Advertisements
Similar presentations
STRING AN EXAMPLE OF REFERENCE DATA TYPE. 2 Primitive Data Types  The eight Java primitive data types are:  byte  short  int  long  float  double.
Advertisements

IT 325 OPERATING SYSTEM C programming language. Why use C instead of Java Intermediate-level language:  Low-level features like bit operations  High-level.
© Janice Regan, CMPT 128, February CMPT 128: Introduction to Computing Science for Engineering Students Pointers.
23-Apr-15 Abstract Data Types. 2 Data types I We type data--classify it into various categories-- such as int, boolean, String, Applet A data type represents.
Types, Variables and Operators Computer Engineering Department Java Course Asst. Prof. Dr. Ahmet Sayar Kocaeli University - Fall 2013.
Liang, Introduction to Java Programming, Sixth Edition, (c) 2005 Pearson Education, Inc. All rights reserved Chapter 2 1 Chapter 2 Primitive.
Primitive Data Types There are a number of common objects we encounter and are treated specially by almost any programming language These are called basic.
Data Types in Java Data is the information that a program has to work with. Data is of different types. The type of a piece of data tells Java what can.
Java Syntax Part I Comments Identifiers Primitive Data Types Assignment.
CSE115: Introduction to Computer Science I Dr. Carl Alphonce 219 Bell Hall Office hours: M-F 11:00-11:
IAT 800 Foundations of Computational Art and Design Lecture 2.
Primitive Types Java supports two kinds of types of values – objects, and – values of primitive data types variables store – either references to objects.
Introduction to Programming Prof. Rommel Anthony Palomino Department of Computer Science and Information Technology Spring 2011.
CSCI 1100/1202 January 16, Why do we need variables? To store intermediate results in a long computation. To store a value that is used more than.
1 Do you have a CS account? Primitive types –“ building blocks ” for more complicated types Java is strongly typed –All variables in a Java program must.
Introduction to Programming David Goldschmidt, Ph.D. Computer Science The College of Saint Rose Java Fundamentals (Comments, Variables, etc.)
Basic Java Programming CSCI 392 Week Two. Stuff that is the same as C++ for loops and while loops for (int i=0; i
JAVA Tokens. Introduction A token is an individual element in a program. More than one token can appear in a single line separated by white spaces.
Geoff Holmes and Bernhard Pfahringer COMP206-08S General Programming 2.
Java 2 More Java Then Starbucks ;-). Important Terms Primitive Data – Basic, built-in values (characters & numbers) Data Type – Used to talk about values.
JAVA 0. HAFTA Algorithms FOURTH EDITION Robert Sedgewick and Kevin Wayne Princeton University.
 JAVA Compilation and Interpretation  JAVA Platform Independence  Building First JAVA Program  Escapes Sequences  Display text with printf  Data.
BUILDING JAVA PROGRAMS CHAPTER 2 PRIMITIVE DATA TYPES AND OPERATIONS.
Chapter 2: Java Fundamentals
Java Simple Types CSIS 3701: Advanced Object Oriented Programming.
Primitive Variables.
An Introduction to Java – Part 1 Dylan Boltz. What is Java?  An object-oriented programming language  Developed and released by Sun in 1995  Designed.
Mixing integer and floating point numbers in an arithmetic operation.
Basic Java Syntax COMP 401, Spring 2014 Lecture 2 1/14/2014.
BEGINNING PROGRAMMING.  Literally – giving instructions to a computer so that it does what you want  Practically – using a programming language (such.
Primitive Variables.
Java Programming, Second Edition Chapter Two Using Data Within a Program.
COMP Primitive and Class Types Yi Hong May 14, 2015.
Component 4: Introduction to Information and Computer Science Unit 5: Overview of Programming Languages, Including Basic Programming Concepts Lecture 3.
School of Computer Science & Information Technology G6DICP - Lecture 4 Variables, data types & decision making.
COM S 207 Literal, Operator, and Expression Instructor: Ying Cai Department of Computer Science Iowa State University
LCC 6310 Computation as an Expressive Medium Lecture 2.
Java Nuts and Bolts Variables and Data Types Operators Expressions Control Flow Statements Arrays and Strings.
Spring 2009 Programming Fundamentals I Java Programming XuanTung Hoang Lecture No. 8.
 Variables are nothing but reserved memory locations to store values. This means that when you create a variable you reserve some space in memory. 
CSC 142 F 1 CSC 142 References and Primitives. CSC 142 F 2 Review: references and primitives  Reference: the name of an object. The type of the object.
Java Basics. Tokens: 1.Keywords int test12 = 10, i; int TEst12 = 20; Int keyword is used to declare integer variables All Key words are lower case java.
Sudeshna Sarkar, IIT Kharagpur 1 Programming and Data Structure Sudeshna Sarkar Lecture 3.
1 2. Program Construction in Java. 01 Java basics.
1 Lecture # 2. * Introducing Programming with an Example * Identifiers, Variables, and Constants * Primitive Data Types * Byte, short, int, long, float,
Review A program is… a set of instructions that tell a computer what to do. Programs can also be called… software. Hardware refers to… the physical components.
Basic Data Types อ. ยืนยง กันทะเนตร คณะเทคโนโลยีสารสนเทศและการสื่อสาร มหาวิทยาลัยพะเยา Chapter 4.
Topics for today: 1.Comments 2.Data types 3.Variable declaration.
Object Oriented Programming Lecture 2: BallWorld.
CPSC 233 Tutorial January 21 st /22 nd, Linux Commands.
Chapter 2 Variables and Constants. Objectives Explain the different integer variable types used in C++. Declare, name, and initialize variables. Use character.
Elementary Programming
Type Conversion, Constants, and the String Object
Java Programming: From Problem Analysis to Program Design, 4e
Principles of Computer Programming (using Java) Chapter 2, Part 1
5 Variables, Data Types.
Unit-2 Objects and Classes
Computers & Programming Languages
Introduction to Java Programming
An Introduction to Java – Part I, language basics
Wrapper Classes The java.lang package contains wrapper classes that correspond to each primitive type: Primitive Type Wrapper Class byte Byte short Short.
An overview of Java, Data types and variables
Introduction to Primitive Data types
Sridhar Narayan Java Basics Sridhar Narayan
Programs and Classes A program is made up from classes
IAT 800 Foundations of Computational Art and Design
The switch Statement When we want to compare a variable against several values to see which one it has, we can use the switch statement: switch (status)
LCC 6310 Computation as an Expressive Medium
Variables and Constants
Introduction to Primitive Data types
Presentation transcript:

Java Programming Review 1 7 Java Programming Review 1

Previously Hello World! Code Blocks Methods Statements Style & Comments Simple Arithmetic Primitive Data Types are keywords (this is way I express them in red) Java provides a map from primitive data types to object: boolean  Boolean, byte Byte, char  Character, short  Short, int  Integer, long  Long, float  Float and double  Double The object version of the primitive data types are defined in the java.lang package

Previously Variables: hold information Primitive Data Types Decision Making Control Structures Error Handling

Labs Tomorrow!!! 9am (until 11am) Room A32, Computer Science Then every Tuesday . . . .

Overview http://webservices.cs.nott.ac.uk/G64ICP/viewforum.php?f=17&start=0

Eclipse for Education