Presentation is loading. Please wait.

Presentation is loading. Please wait.

C + 1 == C++ ce153c Introduction2programming © 2006 NematAllah Ahmadyan.

Similar presentations


Presentation on theme: "C + 1 == C++ ce153c Introduction2programming © 2006 NematAllah Ahmadyan."— Presentation transcript:

1 C + 1 == C++ ce153c Introduction2programming © 2006 NematAllah Ahmadyan.

2 History C was designed by Ritchi, Tompson, Kernighan It was fast, good & powerful but program’s maintance was a nightmare! Solution:... Object-Oriented Programming

3 C++

4 Object-Oriented Polymorphism Inheritance Encapsulation Data Abstraction Operator overloading STL { Standard Template Library } Templates streams Don’t Panic, They’ll become clear later!

5 What is C++ ? “C++ is a general purpose programming language with a bias towards systems programming that is a better C, supports data abstraction, supports object oriented programming, and supports generic programming.” By Bjarne Stroustrup

6 Hello, World &... 1. #include 2. #include 3. #include 4. using namespace std; 5. int main(){ 6. cout << “Hello,World” << endl ; 7. int x = sin(6.28); 8. cout << fixed << setprecision(5) << M_PI ; 9. cout << scientific << x<< endl ; 10. return 0 ; }

7 Another piece of cake! 1.... 2. int x = 0, y = 1; 3. cin >> x ; 4. if ( x == 1 ){ 5. y = f(3); 6. }else{ 7. y = f(5); } 1. int f(int x){ 2. return x%2 ; } C++ is very similar to C C is a mother nature! To all other language. C++, Java even Matlab!

8 Further readings A Brief Look at C++ Paper by Bjarne Stroustrup Addison Wesley - C++ Common Knowledge Advance Programming [Java] course ce244 Lecturer: Ramtin Khosravi Ph.D Object-Oriented Programming

9 Books/Ebooks K&R C  Kernighan,Ritchie [ designers of C ] The C++ Programming Language 3 rd Ed. Bjarne Stroustrup [ designer of C++ ] C Primer / C++ Primer C++ FAQ/ C++ FAQ Lite Dietel & Dietel C/C++/VC++/.NET How to program series Thinking in C++ Vol 1&2 Effective C++ Vol 1&2 McGraw-Hill - C & C++ Programmers Reference Ansi/ISO C++ Numerical Recipes in C [ cambridge ] Scientific Calculation [ MathLab ] [ math department ]

10


Download ppt "C + 1 == C++ ce153c Introduction2programming © 2006 NematAllah Ahmadyan."

Similar presentations


Ads by Google