Are you new into the field of computers? Are you a newbie in programming???
Does your high school syllabus has C & C++ in the course?
If yes, then first of all, let me tell you one small thing. Despite of all the disadvantages of programming in C++ it is recommended to learn before starting with programming, as it does help with improvement of various fundamental concepts of OOPs, which is a required base for programming in PHP and several other scripting languages. C++ works on OOPs i.e. Object Oriented Programming .
OOP concept focuses on create similar objects under a class to perform different function. Such an environment is healthy, as it promotes re-usability of code and memory. Data Abstraction is another feature of the OOPs concept, it means that the user does not have to deal with whatever process is going on behind the program, he is just prompted with the actual & required inputs & outputs. He does not need to know the mechanism which empowers a program.
When I was in class 6th, i tried hands on C++, it was good dealing with graphics.h… People forget to use c://tc//bgi as the location for graphics file…..
.. silly errors made me think that programming using C++ is really wonderful. One of my good friends had a good passion about C++ and he designed power point like animations on C++.. now after exhaustive research with graphics.h, i am too able to make such transitional effects. You can download the TURBO C 3 Compiler from Techite’s Library using the link http://www.techite.com/TC.exe .
A SAMPLE SOURCE CODE IN C++ FOR SOLVING QUADRATIC EQUATION
#include
#include
#include
void main(){
float a, b, c, d, root1, root2;
clrscr();
for(int i=0; i<80; i++){
cout<<”*”;
}
cout< cout<<” Quadratic Equation Solver By SHASHI PRAKASH AGARWAL”;
cout< for(i=0; i<70; i++){
cout<<” _____________________________”;
cout< }
cout<<” A Sample Equation is in the form of :”;
cout<<”ax^2 + bx +c = 0 “;
cout< for(i=0; i<10; i++){
cout<<” ********* PROGRAM LOADING ***”;
cout< }
cout<<” Enter the value of a or coefficient of x^2:”;
cin>>a;
cout<<” Enter the value of b or coefficient of x:”;
cin>>b;
cout<<” Enter Constant Co-efficient or C:”;
cin>>c;
d=b*b – (4*a*c);
root1=(-b+sqrt(d))/(2*a);
root2=(-b-sqrt(d))/(2*a);
cout<<” *************************”;
cout<<” Roots of Equation are “;
cout< getch();
}
———————————————————–
Comments are closed.
