Overview of Java CSCI 392 Day One. Running C code vs Java code C Source Code C Compiler Object File (machine code) Library Files Linker Executable File.

Slides:



Advertisements
Similar presentations
Designing a Program & the Java Programming Language
Advertisements

Data Structures Lecture 1 Fang Yu Department of Management Information Systems National Chengchi University Fall 2011.
Object Orientated Programming
Remote Method Invocation Chin-Chih Chang. Java Remote Object Invocation In Java, the object is serialized before being passed as a parameter to an RMI.
Introduction to Java Programming
Java Intro. A First Java Program //The Hello, World! program in Java public class Hello { public static void main(String[] args) { System.out.println("Hello,
01 Introduction1June Introduction CE : Fundamental Programming Techniques.
Hello, world! Dissect HelloWorld.java Compile it Run it.
CS107 Introduction to Computer Science Java Basics.
Lecture 1: Overview of Java. What is java? Developed by Sun Microsystems (James Gosling) A general-purpose object-oriented language Based on C/C++ Designed.
01 Introduction to Java Technology. 2 Contents History of Java What is Java? Java Platforms Java Virtual Machine (JVM) Java Development Kit (JDK) Benefits.
CMSC 341 Introduction to Java Based on tutorial by Rebecca Hasti at
Developing User Interfaces (DUI) Chris North cs3724: HCI.
Programming in Java; Instructor:Moorthy Introduction, Objects, Classes, Libraries1 Programming in Java Introduction.
“Introduction to Programming With Java”
Computer Programming 12 Mr. Jean March 3 rd, 2014.
Introduction to Java CSIS 3701: Advanced Object Oriented Programming.
An intro to programming. The purpose of writing a program is to solve a problem or take advantage of an opportunity Consists of multiple steps:  Understanding.
Java Lecture 16: Dolores Zage. WWW n Was a method for distributing passive information n added forms and image maps n interaction was only a new way to.
CS107 Introduction to Computer Science Java Basics.
FRST JAVA PROGRAM. Getting Started with Java Programming A Simple Java Application Compiling Programs Executing Applications.
1 Module Objective & Outline Module Objective: After completing this Module, you will be able to, appreciate java as a programming language, write java.
Java Spring PImage Let’s look at the PImage class in ProcessingPImage –What are the fields (i.e., variables)? –What methods are available? –What.
Chapter 1: Introducing JAVA. 2 Introduction Why JAVA Applets and Server Side Programming Very rich GUI libraries Portability (machine independence) A.
OOP (Java): Simple/ OOP (Java) Objectives – –give some simple examples of Java applications and one applet 2. Simple Java Programs Semester.
CS 11 java track: lecture 1 Administrivia need a CS cluster account cgi-bin/sysadmin/account_request.cgi need to know UNIX
© 2012 Pearson Education, Inc. All rights reserved. 1-1 Why Java? Needed program portability – Program written in a language that would run on various.
Java Programming, Second Edition Chapter One Creating Your First Java Program.
Java Introduction 1. Introduction to Java Programming2 Computers and Computer Languages Computers are everywhere –how many computers do you own? Computers.
Java means Coffee Java Coffee Beans The name “JAVA” was taken from a cup of coffee.
Clement Allen, PhD Florida A&M University SUMMER 2006.
2-1 Hardware CPU Memory - 2 kinds Network Graphics Input and Output Devices.
CHAPTER 3 GC Java Fundamentals. 2 BASICS OF JAVA ENVIRONMENT  The environment  The language  Java applications programming Interface API  Various.
Programming Fundamentals 2: Simple/ F II Objectives – –give some simple examples of Java applications and one applet 2. Simple Java.
4-Nov-15 Air Force Institute of Technology Electrical and Computer Engineering Object-Oriented Programming Design Topic 1: The Java Environment Maj Joel.
J ava P rogramming: From Problem Analysis to Program Design, From Problem Analysis to Program Design, Second Edition Second Edition D.S. Malik D.S. Malik.
Chapter 1: Introducing JAVA. 2 Introduction Why JAVA Applets and web applications Very rich GUI libraries Portability (machine independence) A real Object.
A Look at Java. Categorize Java Which paradigm? Which paradigm? Scripting? Scripting? Declarative or procedural? Declarative or procedural? Which generation?
Core Java Introduction Byju Veedu Ness Technologies httpdownload.oracle.com/javase/tutorial/getStarted/intro/definition.html.
Final Jeopardy Fundamen tal Java Numerical Data type Boolean Expressi on If/THEN/ WHILE Miscellan eous
CSE 1341 Honors Note Set 2 1. Overview  Java vs. C++  Functions in C++  First Programming Packet  Development Environment 2.
© 2012 Pearson Education, Inc. All rights reserved types of Java programs Application – Stand-alone program (run without a web browser) – Relaxed.
introductory lecture on java programming
CHAPTER 1 INTRODUCTION. CHAPTER GOALS To understand the activity of programming To learn about the architecture of computers To learn about machine code.
3/5/2002e-business and Information Systems1 Java Java Java Virtual Machine (JVM) Java Application Program Interface (API) HW Kernel API Application Programs.
Computer Science A 1. Course plan Introduction to programming Basic concepts of typical programming languages. Tools: compiler, editor, integrated editor,
Execution ways of program References: www. en.wikipedia.org/wiki/Integrated_development_environment  You can execute or run a simple java program with.
Features of JAVA PLATFORM INDEPENDENT LANGUAGE JAVA RUNTIME ENVIRONMENT (JRE) JAVA VIRTUAL MACHINE (JVM) JAVA APP BYTE CODE JAVA RUNTIME ENVIRONMENT.
Introduction to 1. What is Java ? Sun Microsystems Java is a programming language and computing platform first released by Sun Microsystems in The.
CPSC 233 Tutorial January 21 st /22 nd, Linux Commands.
Sung-Dong Kim, Dept. of Computer Engineering, Hansung University Java - Introduction.
Introduction CMSC 202 Fall Instructors Mr. Ryan Bergeron – Lecture Section 01 Tues/Thu 1:00 – 2:15 am, Sondheim 111 – Lecture Section 04 Tues/Thu.
CS-140 Dick Steflik Lecture 3. Java C++ Interpreted optimized for the internet Runs on virtual ized machine Derived from C++ Good object model Widely.
Introduction to.
Internet and Java Foundations, Programming and Practice
Lecture Note Set 1 Thursday 12-May-05
Intro to Java.
Going from C++ to Java Jayden Navarro.
Comp Sci 200 Programming I Jim Williams, PhD.
Getting Started ARCS Lab..
An Introduction to Java – Part I, language basics
Introduction CSC 111.
Java Intro.
(Computer fundamental Lab)
Debugging Exercise 00 Try compiling the code samples.
Chap 1. Getting Started Objectives
Chap 4. Programming Fundamentals
F II 2. Simple Java Programs Objectives
Computer Programming-1 CSC 111
Presentation transcript:

Overview of Java CSCI 392 Day One

Running C code vs Java code C Source Code C Compiler Object File (machine code) Library Files Linker Executable File (machine code) Java Source Code Java Compiler Java Byte Code Java Platform (API) Java Virtual Machine (interpreter / JIT compiler) portable between machine types

Java Design Features Byte Code is machine independent Network-Centric provides OS-type services security is a fundamental concern Java 5.0 includes 3562 classes in 166 packages, including support for client-server operation concurrency parsing web data etc

Hello World 1.0 class hello { static void main (String[] args) { System.out.println("Hello World"); } $ vi hello.java $ javac hello.java $ ls hello.class hello.java $ java hello Hello World

Hello World 1.1 public class hello2 { public static void main (String[] args) { int num_loops; // numbers of hellos to print // test the user input if (args.length != 2) { System.out.println("Usage Error: java hello2 name count"); return; } // convert the command line arg from string to int num_loops = Integer.parseInt (args[1]); // print the hellos for (int i=0; i<num_loops; i++) System.out.println("Hello " + args[0]); }