PHP programs with visual output | Basic programs on PHP

bellow is the PHP program.that may help you to done your practical records,each program had give visual output so you can catch those program in very simple. Before going discuss program lets discuss HOW TO RUN PHP PROGRAM using wampserver

Steps to Run php file with WAMP SERVER

  1. Save the file WAMP -> WWW -> filename.php
  2. Run WAMPSERVER.
  3. Now open a Browser and Type Localhost
  4. Now open a localhost main page there you can see Your projects
  5. Select that file to run
The server side scrpting provide much of the sophisticated of general CGI with the ease of HTML. The idea behind of server-side script is simble. First create a page using Standard HTML or XHTML ,Then add special elements of code directives to indicate what to do in particular cases PHP,which stands for Hypertext Preprocessor(a recursive acronym,originally stood for personal homepage) is general purpose Server-side scripting language that was originally designed for web development to produce dynamic web page. PHP interpreter only execute PHP code with its delimiters.Anything outside its delimiters is not processed by PHP .
Every file should save with .Php extenstion
There are few fine points about how PHP code work:
  • The web sever sends the request on to the PHP parser,which is either built into the web server binary or exists seperately as filter
  • The PHP parser scan the requested file for PHP code
  • when PHP parser finds PHP code.it execute
  • New output file is sent back to the web server
  • The web server sends the output file along to the web browser
  • The web server display the output




Basic php programs with connecting to SQL databases

  1. PHP programs to Print Even numbers in a range
  2. PHP program to Demonstrate use of COOKIES
  3. PHP program to concatenate two string
  4. PHP program to find large number in Array
  5. PHP program to display element in an Array in ascending order
  6. PHP program to display elements in an array using Foreach loop
  7. PHP program to demonstrate Switch control statements
  8. PHP program to display first n STRANGE numbers
  9. PHP program to display first n PRIME numbers
  10. PHP prgrams to print PRIME number in a RANGE
  11. PHP program to print FIBONACCI numbers in a RANGE
  12. PHP program to demonstrate any five STRING Functions
  13. PHP program create HTML form page and POST its value to another page
  14. PHP program to create login form with help of session
  15. PHP program to store,display,update,and delete students details using Mysql database
  16. PHP program to populate dropdown (select) box with data from MySQL table
  17. PHP program to populate content of student table to HTML form
more updates will coming soon....

Generations of Computers amd | Five generation of computers

Generation of Computers with examples -Five Generations of computers advantages and disadvantages generation of computers

Generation Of Computers

Computers were developed in five distinct phases known as computer generations. There are totally Five computer Generations known till today.
  1. First Generation computers(1945-55)
  2. Second Generation Computers(1956-64)
  3. Third Generation Computers(1965-74)
  4. Fourth Generation Computers(1975 - onwards)

First Generation computers(1945-55)

First Generation Computers used thermionic tubes(Vacuum tubes) as basic elements.Programs and their data were located in the same memory, as they are today.First generation ASSEMBLY language was used to prepare programs and was translated into machine language for execution.Basic arithmetic operations were performed in a few milliseconds. Input/Output functions were performed by devices similar to typewriters.Magnetic core memories and magnetic tape storage devices were also developed .
Examble of first generation computers :

ENIAC,EDVAC,EDSAC,MARK 1 and UNIVAC
-(Show those in details)

Advantages of First generation computers

  1. VACUUM TUBE were the only electronic components available during those days.
  2. VACUUM technology made possible the advent of electronic digital computers.
  3. These computers were the faster calculating devices of their time. They could perform computation in MILLISECONDS

Disadvantages of first generation computers

  1. Too bulk in size and hence very large space required
  2. Unreliable
  3. Thousands of Vaccum tubes that were used emitted large amount of heat and burnt out frequently
  4. Slow operating speed and restricted computing capacity
  5. High power consumption and short life span
  6. Air conditioining required
  7. Frequent hardware failure
  8. Constant Maintenance required
  9. Non portable
  10. Manual integration of individual components into functioning unit required
  11. Commercial production was difficult and costly.
  12. Limited programing capabilities and hence, limited commercial use

Second Generation Computers(1956-64)

The second Generation began with the advent of TRANSISTORISED CIRCUITRY,Magnetic core and Magnetic drum storage devices were widely used in second generation.The high reliability and large storage availability lead to the development of the high-level languages like FORTAN,COBOL,ALGOL etc., making the preparation of application programs much easier . System programs called compiler were developed to translate the high level language programs into corresponding Executable machine language form.
Separate I/O processors were developed that could operate parallel to the Central processor that executed programs, thus improving overall performance.IBM became the major computer manufacture during this time
Examples of second generation computers:

  • IBM 1620 (Scientific)
  • IBM 1401 (Business)
  • IBM 7094 (Scientific and Business)
  • CDC 1604 (Scientific)
  • CDC 3600 (Scientific)
  • RAC 501 (Business)
  • UNIVAC 1108 (Scientific and Business)

Advantages of Second Generation Computers

  1. Smaller in size as compared to First Generation Computers
  2. More reliable
  3. Lower power consumption and hence reduced running cost
  4. Higher operating speed.Computational time reduced from Milliseconds to Microseconds
  5. Less Prone to hardware failure
  6. Better portability
  7. Reduced manufacturing cost and hence wider commercial use

Disadvantages of Second Generation Computers

  1. Air conditioning was required
  2. Frequent maintenance was required
  3. Manual integration of individual components into functioning units was required
  4. Commercial production was difficult and costly

Third Generation Computers(1965-74)

The ability to fabricate many transistors on a chip called IC technology, Enabled low-cost and faster processors and memory elements to be built. IC memories began to replace Magnetic core memories.These technological developments marked the beginning of the third generation. Other developments includes the introduction of microprogramming, parallelism and pipelinig.
Cache and virtual memories were developed,operating system allow to efficient sharing computer system.
Examples of Third Generation computers:
  • IBM 360 series
  • IBM 370/168
  • ICL 1900 series
  • ICL 2900
  • HONEY WELL MODEL 316
  • HONEY WELL 6000 series
The development of Large Scale Integration(LSI) and Very Large Scale Integration(VLSI) and microprocessor chips help to manufacturing of minicomputers,mainframe computers.

Advantages of Third Generation computers

  1. Smaller in size compared to previous generation computers
  2. More reliable than second-generation computers
  3. Lower heat generated
  4. Computational time reduced from microseconds to nanosecond
  5. Maintenance cost is low because hardware failure are rare
  6. Easily portable
  7. Totally general purpose Widely used for various commercial application all over the world
  8. Less power required than previous generation computers
  9. Manual integration was not required
  10. Commercial production was easier and cheaper
  1. Air conditioning required in many cases
  2. Higher sophisticated technology required for the manufacturing of IC chips

Fourth Generation Computers(1975 - onwards)

Very Large Scale Integration (VLSI) technology had evolved to the point where the computer processor could be fabricated on a single chip. This came to be known as MICROPROCESSOR. The development of the microprocessor made it possible to place complete Central Processing Unit(CPU) on a single chip. those computers are called microcomputers.
Computers organization concept such as Parallelism,piplining and cache and virtual memories help to produce high performance computing systems of today as the fourth generation.Interconnection of Desktop computers by using Local Area Network(LAN)

Advantages of Fourth Generation Computers

  1. Smallest in size because of high density of components in a single chip
  2. More reliable
  3. Heat generated is negligible
  4. Air-Conditioning was not required in many cases
  5. Much faster in computation
  6. Hardware failure is negligible and hence minimal maintenance cost<./li>
  7. Easily Portable because of their small size
  8. Totally general purpose
  9. Minimal labour cost involve at assembly stage
  10. Cheapest among all generations

Disadvantages of Fourth Generation computers

  1. Highly sophisticated technology required for the manufacturing of VLSI chips

Fifth Generation Computers(Yet to Come)

The fifth Generation computers are under development .Scientists are now at work on the fifth generation computers.

Characteristics of Fifth Generation computers

  • Parallel processing instead of serial processing and will be able to do multiple tasks simultaneously
  • Perform knowledge processing instead of data processing
  • It will interact with humans in natural language instead of computer language
  • It will interact with humans in natural language instead of computer language
  • Super speed
  • Behave like an expert and show Artificial intelligence


Evolution Of Computer | Brief history of computer | History of Electronic computers

History and Evolution of computers,Electronic computer
history of computer

Need is the mother of invention. Because computers are evolved as result of man's continues research for finding Fast and accurate calculating devices.The effort are still continuing to make machine more and more versatile

The stone age used pebbles for counting. /later on when man become more civilized, Abacus cam in use. Abacus seems to be the earliest calculating machine , which was developed by Chinese 3000 years ago. Al thought the Abacus was invented around 600 BC, it is still used in the Far East and its users can do calculations at an amazing speed

another manual calculating device was John Napier's Bone or Cardboard Multiplication calculator. john Napier, the 17 the century mathematician, devised a set of rods for use in calculators involving multiplication. These Rods were carved from bones and therefore called Napier's Bones.

The first adding machine was invented by a French Mathematician Blase pascal in 1642. His machine was a simple calculator used for addition and substraction purposes.This machine was later modified By a German, Gottfriend Lebnnitz, in 1671.This was the first machine to multiply and divide directly.

Charles Babbage, a 19th century at Cambridge University, is considered to be the father of the modern digital computers.Babbage made a calculating machine called Different Engine in the year 1822 which could evaluate accurately algebraic expressions and mathematical tables correct up to 20 decimal places.In 1842 Babbage came out with his new idea of analytical engine that was intended to be completely automatic.

Electronic Computers

A mechanical computer has two drawbacks.

  • Computing speed is limited by the inertia of its moving parts
  • The transimission of digital information by mechanical means is quite unreliable
by
The electronic computer moving parts are electronic device such as the Vacuumtube or electronic valve, which was developed in the early 1900's, permit the processin and storage of digital signals at speeds far exceeding those of any mechanical devise

We will now discuss some of the well known early electronic computers.
  1. The Mark 1 computers(1937-44)
  2. The ENIAC computers(1943-46)
  3. The EDVAC computers(1949-52)
  4. The EDSAC computers(1947-49)
  5. The UNIVAC computers(1951)

Mark 1 computers(1937-44)

Mark 1 was the fully fully automatic calculating machine designed by Howard A Aiken of Hardvard University in collaboration with International Business Mechanism(IBM) corporation. Its design was based on the technique already developed for punched card Machnery. Al thought this this machine proved to be extremely reliable, It was very complex in design and huge in size. It used over 3000 electrical switches to control its operation and was approximately 50 feet long and 8 feet high. it was capable of performing five basic arithatic operation :

Addition,Subtraction, multiplication,division and table reference
A number as big as 23 decimal digits could be used in this machine.It took approximately 0.3 second to add two numbers and 4.5 second for multiplication of two numbers. It was basically an electro mechanical device since both mechanical and electronic components were used in its design.

ENIAC-(Electronic Integrator And Calculator) computers(1943-46)

The Electronic Integrator And Calculator was the first fully electronic computer.this mechine was designed and compiled in 1946 by J P Eckert and J M Mauchly at the moore school of Electronic Engineering at the university of pennsylvania, USA. ENIAC was developed for military nedd. It was the first fast machine as compared to its ancestors.
The addition of two numbers was achieved in 200 microseconds, and multiplication in 2000 microseconds.The ENICA has 30 tons and containing more than 18000 vacuum tubes.The ENIAC computer is faster than Mark 1 computer and now microcomputers are 5000 times faster than ENIAC computers.

EDVAC-(Electronic Discrete Variable Automatic Computers) computers(1949-52)

The Electronic Discrete Variable Automatic Computers(EDVAC) was the first computer that was designed on stored programs concept. Developed by Dr. John Von Neumann. The basic idea behind the stored program concept is that a sequence of instructions as well as data can be stored in the memory of the computer for the purpose of automatically directing the flow of operations.The stored program concept allows much faster operation since the computer has rapid access to both program and data.
The other advantages of stored programs is the logical decision can tack internally. The stored program feature considerably influenced the development of modern digital computers and because of the feature, modern digital computers are often called stored program digital computes

EDSAC -(Electronic delay storage automaic Calculator)computers(1947-49)

Almost simultaneously with EDVAC of USA , the britishers developed the Electronic delay storage automaic Calculator (EDSAC). In EDSAC additon operation was accomplished in 1500 microsecconds. This machine was developed by a group of scientists headed by professor Maurice Wilkes at Cambridge university Mathmatical Laboratory.

UNIVAC-(Universal Automatic Computer) computers(1951)

Universal Automatic Computer (UNIVAC) was the first digital computer. It was produced in 1951 by Universal Accounting Company set up by Eckert and Mauchly. This machine used magnetic medium for data input and output.

Introduction to computers

Definition and Characteristics of computers

What is a computer - characteristics of computers

What is a computer?

The word computer comes from the word 'compute', which means to calculate.so a computer is normally consider to be a calculating device that can perform arithmetic operation at enormous speed. The original objective for inventing the computer was to create a fast calculating machine. But more than 80% of the work done by the computers today is of non mathematical nature. Computer appears differently to different peoples.The computer appears to be magic Box to a layman.it strike him simply as a calculator, which works automatically.To one with technical know-how, the computer is a sophisticated electronic device caple of solving problems or manipulating data by accepting data and instruction, performing the prescribed operation on data and supplying the results of these operations as output.
More accurately,a computer may be defined as a fast and accurate sophisticated electronic data processing device that is designed to automatically accept, store and process data and produce output results under the direction of a stored program


Characteristics of Computer

Computer have the following characteristics.

  1. speed:  A computer is very fast device. Computer makes calculation at an amazing speed without any mistakes.Even a microcomputer can make as many calculations in one minute that may take the entire life of a scientist or an engineer.A moder computer can excute several millions of instructions per second(MIPS). The speed of a computer is usually measured in microseconds ,nanoseconds and pico seconds.
  2. Accuracy:   The accuracy of a computer is consistently high and the degree of accuracy of a particular computer depends upon its design. Error can occur in a computer, but these are mainly man made, such as inaccurate data and imprecise thinking of programmers rather than technical weaknesses.

  3. Versatility:   A computer is capable of performing almost any task provided that the task can be reduced to a series of logical steps.

  4. High Storage capacity :   Computers can store large amount of data and information in very small space and any part of it can be retrieved as and when required , in a microsecond or even less.

  5. Reliability:   Computers components are designed in very high life and degree of reliability.Computer make calculations without tiring and making any mistakes due to boredom or fatigue

  6. No intelligence :   Computers have no intelligence of their own.Computer cannot make any judgment of their own,their judgment is based on the instruction given to them by the user


Install operating system using bootable pendrive

Install operating system using pen drive without a cd

Instal os using pendrive

Here we will discuss about how to install operating system using a boo table pen drive. By using it we no need to find an extra DVD or any thing for install os. We just need to type some query on command prompt which may call as CMD. For create a bootable pendrive we should follow some steps
  1. Open DISKPART
  2. Type- LIST DISK
  3. SELECT DISK 1
  4. CLEAN -the disk
  5. CREATE PARTITION PRIMARY
  6. SELECT PARTITION PRIMARY
  7. SELECT PARTITION 1
  8. type -format fs = ntfs quick
  9. ASSIGN
  10. ACTIVE
Those are the steps for create a boo table pendrive. Those have discussed bellow with picture First our pen drive should boot. The purpose of this is to open pen drive at the time booting like our internal hard disk.So we can start for
Create a bootable pendrive
  1. open cmd(command prompt)
    • search for "cmd"
    • open RUN using WINDOW key+R
  2. Then press ok.which will open a black window named cmd.exe
  3. Type "DISKPART" then press enter
  4. Which will open a new black window named diskpart.exe
  5. Type "LIST DISK" press enter Which will show all drives
  6. By type list disk show all your disks by disk 0,disk 1.
  7. Now select your disk. So Type "SELECT DISK 1" (disk 0 is hard disk) and press enter
  8. Type "CLEAN" - for clean the disk. ones we clean we can not recover it. then press enter
  9. Type "CREATE PARTITION PRIMARY" Then press enter
  10. Then Type "SELECT PARTITION 1" then press enter
  11. Type 'format fs = ntfs quick' (it is for format the drive quickly) and press enter
  12. Then Type "ASSIGN" then press Enter
  13. Then type "ACTIVE" press enter
  14. Now your pen drive is bootable.we can check it by checking the memory space.some amount of memory had used
  15. Now copy your windows file to our pendrive and enjoy....