Computer Science Notes

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

The single most important skill for a computer scientist is problem solving.

It
involves the ability to formulate problems, think creatively about solutions,
and express solutions clearly and accurately. As it turns out, the process of
learning to program is an excellent opportunity to develop problem solving
skills. That’s why this chapter is called, “The way of the program.
input:
Get data from the keyboard, a file, a sensor, or some other device.
output:
Display data on the screen, or send data to a file or other device.
math:
Perform basic mathematical operations like addition and division.
decisions:
Check for certain conditions and execute the appropriate code.
repetition:
Perform some action repeatedly, usually with some variation.
An algorithm is a sequence of steps that specifies how to solve a problem.

Import java.

Public static void main(String[] argos) {

Scanner keyboard = new scanner

int//
System.out.println(“Enter your age ::”);
Int userAge = keyboard.netInt();
System.out.println(“Your age is “ + userAge);

You might also like