Learning Unit 1 Programming Theory Flashcards
(12 cards)
Purpose of a programmer
To code programs to be used by the end user.
System.out.print or Sytem.out.println()
Uses print() or println() method will display (output window). Whatever is in the round brackets after method name.
Print method displays what
Is in brackets on output window and next output will be on the same line.
Println method displays what
Is in brackets and next output is on the next line.
Function of round brackets () in methods in Java (after their names)
To identify that they are methods.
Some methods have
Values in the brackets, some do not.
Important to call a method
With the correct number of parameters.
IDE
Integrated Development Environment.
Java IDE
Enables you to type in code for a Java program and provides options to compile and run your program.
IDE possibly highlights
Certain Java words and comments in a different color/in bold.
Some IDE’s even provide
Functions that will help you find errors in your code while it is running.
When you have a program (_______.java) open your IDE, and you select Compile or Run, the following takes place:
- Java statements are first check for syntax errors (if any errors program can’t compile & error messages display)
- Java program translated into program in Java byte code formate (computer machine code), new file saved with extension class (____.class)
- Successful compilation, bytecode is run.executed by running program
- During execution of program (first statement in main method onwards) output is displayed when relevant statement is carried out