Showing posts with label how to write a program. Show all posts
Showing posts with label how to write a program. Show all posts

Sunday, 29 December 2013

C++ programming

this article is related with my previous topic , which was about c++ programming , here i m going to discuss that article more.

C++ programming

Std::cout

Standard output stream object
“Connected” to the screen
std:: specifies the "namespace" which cout belongs to
std:: can be removed by the use of using statements
with the help of using statement we can write cout instead of std::cout as we would observe in the next program.
<< 
Stream insertion operator 
Value to the right of the operator (right operand) inserted into output stream (which is connected to the screen)

std::cout << “Welcome to C++!\n”;



Indicates that a “special” character is to be output 


There are multiple ways to print text. Following are some more examples.

output 

Testing and debugging 

Bug
A mistake in a program
Debugging
Eliminating mistakes in programs
Term used when a moth caused a failed relay on the Harvard Mark 1 computer.  Grace Hopper and other programmers taped the moth in logbook stating:          “First actual case of a bug being found.”

Program errors

Syntax errors
Violation of the grammar rules of the language
Discovered by the compiler
Error messages may not always show correct location of errors
Run-time errors
Error conditions detected by the computer at run-time
Logic errors
Errors in the program’s algorithm
Most difficult to diagnose
Computer does not recognize an error

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

                                              murad ali shah .......... mobile zone;;;;;;;;;;;;;;we engineer the nation future