Monday, 30 October 2017

introduction to computer and java

Question 08: What language does the CPU understand?
  ANS:  CPU understand only binary code or machine language. Because it is native language of computer.
Question 09: What is an assembly language?.What is an assembler?
Ans:  
      Assembly language:
                           Assembly language use short descriptions words called mnemonics which is used to represent machine instruction.
Example:
       For adding two numbers.           add 4,9 result

 Assembler:
            An assembler is a software that convert assembly language into machine code.

Question 10:   What is a high-level programming language?
  Ans:
          High level language is English like , Which is easy to understand.
The instruction given to computer is called a statement.
Example
            Sum  = a+b;
 Question 11:    What is a source program?
Ans:
         The program  written in high level language is called source program or source code.

Question 12:      What is an interpreter? What is a compiler?
    Interpreter.
                  An interpreter is a software that convert high level language in low level language statement by statement. It is time consuming
  Compiler:
                  A compiler is a software that convert high level into low level language as whole.

Question 13:     What is a keyword? List some Java keywords.

    Keywords are reserved words that have predefine meaning and purpose.
 Key words:byte ,  short ,  int ,  float ,  char , String  ,Boolean , etc.                

Question 14:   Show the output of the following code:
public class Test {
public static void main(String[] args) {
System.out.println("3.5 * 4 / 2 – 2.5 is ");
System.out.println(3.5 – 2.5);
}
}
Output
         3.5 * 4 / 2 – 2.5 is
         4. 5          

Labels:

introduction to java and computer

Question 04:
            What is a bit? What is a byte?
Ans:  A switch has two states on/off when switch is on its value is 1 when switch is off its value is 0.These 0 and 1 are interpreted as binary digit called bit or binary numbers.
And a byte is a combination of eight bit. It is a smallest unit to store data.
Question 05:
              What is memory for? What does RAM stand for? Why is memory called RAM?
Memory   Computer memory is like a box in which we can store any type of data.
RAM  it stands for random asses memory.
RAM  Data can be accessed in any order. It is a volatile memory it means all the information can be lost when computer is turned off.
Question 06: 
                 What unit is used to measure memory size?
The computer storage capacity must be measure in byte.
Their are also some methods to measure the memory size.
Kilobyte(KB)  =   1000 bytes
Megabyte(MB)  =   100000 bytes   
Gigabyte(GB)   =    1000000000 bytes
   Terabyte(TB)   =    1000000000000 bytes
Question 07:
              What is the primary difference between memory and a storage device. ?
  Ans: Computer memory has ordered sequence bytes that can be stored programs and data of programs. A program and its data can be moved to computer memory when computer is turned off.
Important noteA memory byte is never empty but its initial contents is meaningless it can be replaced when new contents is placed in it.
Storage Device:A RAM is a volatile type of storing memory the information that can be stored in RAM when computer is turned off.
Different type of Storage devices
01 Magnetic Disk    02  Optical Disk    03   USB flash
   

Labels:

Saturday, 28 October 2017

introduction to computer and java


Question number 01:
      What is computer:
    ANS    A computer is an electronic device that can that can store and process data in a very short time. A computer is a combination of both software and hardware.
Question number 02:
                                          What are hardware and software and list its some components:
Ans      Hardware:
                                   All the physical components of computer is called hardware that can be touched.
Examples: CPU,Mouse,Keyboard,Moniter,etc;
         Software:
                               A software is an instruction that given to computer that control all the hardware components.
Example:
                  Calculator on desktop,paint function,games,ms word,etc
Question 03:  What does the acronym “CPU” stand for.
  Ans:  It stand for “Coded Rendition Of Names Yielding Meaning”.
Question 04:    What unit is used to measure CPU speed.
Ans: The ALU(arithmetic logic unit) is used to measure the speed of computer.
Important note :Every computer has it own internal clock, Which emit electron at constant rate. The unit measurement of hertz(Hz).The Intel processor speed is about 3 gigahertz.   
     


Labels: