C++ Programming Basics C++ Lecture 1 Stacy MacAllister.

Slides:



Advertisements
Similar presentations
Foundations of Programming and Problem Solving Introduction.
Advertisements

Introduction to Programming in C++ John Galletly.
INTRODUCTION Chapter 1 1. Java CPSC 1100 University of Tennessee at Chattanooga 2  Difference between Visual Logic & Java  Lots  Visual Logic Flowcharts.
CS0004: Introduction to Programming Introduction to Programming.
MC697 Object-Oriented Programming Using Java. In this class, we will cover: How the class will be structured Difference between object-oriented programming.
 2005 Pearson Education, Inc. All rights reserved Introduction.
Creating a Program In today’s lesson we will look at: what programming is different types of programs how we create a program installing an IDE to get.
Your First C++ Program Aug 27, /27/08 CS 150 Introduction to Computer Science I C++  Based on the C programming language  One of today’s most.
1 8/30/06CS150 Introduction to Computer Science 1 Your First C++ Program.
C# Programming: From Problem Analysis to Program Design1 2 Your First C# Program.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
1 An Introduction to Visual Basic Objectives Explain the history of programming languages Define the terminology used in object-oriented programming.
Activity 1 - WBs 5 mins Go online and spend a moment trying to find out the difference between: HIGH LEVEL programming languages and LOW LEVEL programming.
Microsoft Visual Basic 2005 CHAPTER 1 Introduction to Visual Basic 2005 Programming.
Chapter 1: Python Basics CSCI-UA 0002 – Introduction to Computer Programming Mr. Joel Kemp.
Introduction 01_intro.ppt
1 Chapter One A First Program Using C#. 2 Objectives Learn about programming tasks Learn object-oriented programming concepts Learn about the C# programming.
Introducing Java.
Java Programming, 3e Concepts and Techniques Chapter 2 Creating a Java Application and Applet.
A First Program Using C#
INTRODUCTION TO C PROGRAMMING LANGUAGE Computer Programming Asst. Prof. Dr. Choopan Rattanapoka and Asst. Prof. Dr. Suphot Chunwiphat.
Integrated Development Environments (IDEs) CS 21a: Introduction to Computing I First Semester,
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming 1.
Chapter 1: A First Program Using C#. Programming Computer program – A set of instructions that tells a computer what to do – Also called software Software.
Instructor: Tina Tian. About me Office: RLC 203A Office Hours: Wednesday 1:30 - 4:30 PM or .
Python Programming Introduction to programming using python.
Introduction to Programming Peggy Batchelor.
IPC144 Introduction to Programming Using C Week 1 – Lesson 2
Chapter 3: Completing the Problem- Solving Process and Getting Started with C++ Introduction to Programming with C++ Fourth Edition.
Session One Introduction. Personal Introduction Role of programmers Robot Examination HUD & HID Uploading Code.
Programming With C.
Computer Programming TCP1224 Chapter 3 Completing the Problem-Solving Process and Getting Started with C++
History of C 1950 – FORTRAN (Formula Translator) 1959 – COBOL (Common Business Oriented Language) 1971 – Pascal Between Ada.
Jaeki Song ISQS6337 JAVA Lecture 03 Introduction to Java -The First Java Application-
1.1 Introduction to Programming academy.zariba.com 1.
Introduction to programming in the Java programming language.
N from what language did C++ originate? n what’s input, output device? n what’s main memory, memory location, memory address? n what’s a program, data?
1 C++ Programming Basics Chapter 1 Lecture CSIS 10A.
Chapter 0 Getting Started. Objectives Understand the basic structure of a C++ program including: – Comments – Preprocessor instructions – Main function.
1 Computer Science of Graphics and Games MONT 105S, Spring 2009 Session 1 Simple Python Programs Using Print, Variables, Input.
Algorithms  Problem: Write pseudocode for a program that keeps asking the user to input integers until the user enters zero, and then determines and outputs.
C o n f i d e n t i a l 1 Course: BCA Semester: III Subject Code : BC 0042 Subject Name: Operating Systems Unit number : 1 Unit Title: Overview of Operating.
1 COMS 261 Computer Science I Title: C++ Fundamentals Date: September 05, 2005 Lecture Number: 4.
1 Programming Environment and Tools VS.Net 2012 First project MSDN Library.
22-July-2002cse142-13B-Development © 2002 University of Washington1 Development Tools CSE 142, Summer 2002 Computer Programming 1
CPS120: Introduction to Computer Science Compiling a C++ Program From The Command Line.
PROGRAMMING IN PYTHON LETS LEARN SOME CODE TOGETHER!
Computer Science Reaching Wider Summer School 2012.
Exploring Spyder: An IDE for scientific computing
The Development Process Compilation. Compilation - Dr. Craig A. Struble 2 Programming Process Problem Solving Phase We will spend significant time on.
 2007 Pearson Education, Inc. All rights reserved. A Simple C Program 1 /* ************************************************* *** Program: hello_world.
1.1: Objects and Classes msklug.weebly.com. Agenda: Attendance Let’s get started What is Java? Work Time.
Principles of Programming CSEB134 : BS/ CHAPTER Fundamentals of the C Programming Language.
Execution ways of program References: www. en.wikipedia.org/wiki/Integrated_development_environment  You can execute or run a simple java program with.
Evolution of C and C++ n C was developed by Dennis Ritchie at Bell Labs (early 1970s) as a systems programming language n C later evolved into a general-purpose.
1 Types of Programming Language (1) Three types of programming languages 1.Machine languages Strings of numbers giving machine specific instructions Example:
1 8/30/06CS150 Introduction to Computer Science 1 Your First C++ Program.
Microsoft Visual Basic 2012: Reloaded Fifth Edition Chapter One An Introduction to Visual Basic 2012.
Chapter 1: Introduction to Computers and Programming.
CHAPTER 3 COMPLETING THE PROBLEM- SOLVING PROCESS AND GETTING STARTED WITH C++ An Introduction to Programming with C++ Fifth Edition.
Java Programming Fifth Edition Chapter 1 Creating Your First Java Classes.
Introduction to Algorithm. What is Algorithm? an algorithm is any well-defined computational procedure that takes some value, or set of values, as input.
Computer Terms Review from what language did C++ originate?
Microprocessor and Assembly Language
Algorithms Problem: Write pseudocode for a program that keeps asking the user to input integers until the user enters zero, and then determines and outputs.
Introduction Java Chapter 3.
TRANSLATORS AND IDEs Key Revision Points.
Chapter 10 Programming Fundamentals with JavaScript
Computer Terms Review from what language did C++ originate?
CMPT 120 Lecture 3 - Introduction to Computing Science – Programming language, Variables, Strings, Lists and Modules.
Presentation transcript:

C++ Programming Basics C++ Lecture 1 Stacy MacAllister

Course Goals ๏ Introduction to integrated development environments (IDEs) ๏ Crash course in C++ programming ๏ Workable understanding of variables, functions, and objects

Class Structure ๏ Class time from 9-11am and 2-4pm on Monday, Wednesday, and Friday ๏ Class time is used for lectures and worktime ๏ Daily activities reinforcing concepts ๏ Concepts will build on each other so ask questions early 3

Motivation ๏ C++ is a challenging but powerful language ๏ Basis of many major software packages ๏ Concepts in this class extend to many other languages ๏ Today is devoted to the basic building blocks - Setting up the IDE - C++ Syntax - Using Includes - Commenting Code - Output to the Command Line

What is an IDE? ๏ Definition: An integrated development environment (IDE) is a software application that provides comprehensive facilities to computer programmers for software development. An IDE normally consists of a source code editor, build automation tools and a debugger. 5

What is an IDE ๏ Source Code – The letters, numbers, and symbols that make up a program ๏ Build Automation – Translates source code into computer speak ๏ Debugging – Looking though code while running to gain understanding 6

Visual Studio 7 Source Code Build Output Debuggin g Breakpoin t

Checkpoint ๏ Open Visual Studio and and create a new visual C++ Win32 Console Application 8

Properties of C++ ๏ Program statements are executed line-by-line ๏ Lines are terminated with the a ; ๏ Everything starts in the main function ๏ Source code is translated into machine code prior to execution ๏ Syntax similar to other ”curly brace languages” (C, Java, C#) 9

Checkpoint ๏ Obligatory “Hello World!” application. Enter code into IDE and run. ๏ Delete a ; ๏ What happens? ๏ Remove “return 0;” ๏ What happens? 10

Comments ๏ Good programmers comment their code ๏ Comments explain in plain language what a portion of code does ๏ Comments are helpful to yourself and others when reading code 11

Checkpoint ๏ Add your own comments to your Hello World program ๏ What happens when you run the program without the // or /**/ with the text? 12

Include Statements ๏ Remember C++ complies syntax line-by-line ๏ If we want to do something we need the syntax or machine code ๏ There are common operations that users want to perform ๏ Don’t want to reinvent the wheel every time we want a printout ๏ Sooooo we use the standard library and include statements 13

Include Statements ๏ To specify what standard features we want we use #include ๏ Lets us call and use all the functionality in our own program without having to write the code ourselves ๏ For example in our Hello World program we used #include to print to the command line 14

Checkpoint ๏ Uncomment the #include and try to run the program 15

Questions?

Assignment ๏ Play with different wording in your Hello World application ๏ Challenge: Can you split the words onto different lines?