Homework 1 (due:April 8th) Deadline : April 8th 11:59pm Where to submit? eClass “ 과제방 ” (http://eclass.cau.ac.kr) How to submit? Create a folder. The name.

Slides:



Advertisements
Similar presentations
C++ Basics March 10th. A C++ program //if necessary include headers //#include void main() { //variable declaration //read values input from user //computation.
Advertisements

 2000 Prentice Hall, Inc. All rights reserved Fundamentals of Strings and Characters String declarations –Declare as a character array or a variable.
CS1010 Programming Methodology
TDBA66, VT-03 Lecture - Ch. 21 A complete C-program Display Fig. 2.1 and comment on different things such as Preprocessor directives Header files Identifiers.
Introduction to Application Programming IST 256 Application Programming for Information Systems Xiaozhong Liu
Programming is instructing a computer to perform a task for you with the help of a programming language.
Computer Programming Lab(4).
Agenda Review Compiling Review Data Types Integer Division Composition C++ Mathematical Functions User Input Reading: , 8.11 Homework #3.
1.3 Console Input And Output academy.zariba.com 1.
Computer Programming 2 Lab(1) I.Fatimah Alzahrani.
Array Cs212: DataStructures Lab 2. Array Group of contiguous memory locations Each memory location has same name Each memory location has same type a.
BUILDING JAVA PROGRAMS CHAPTER 7 Arrays. Exam #2: Chapters 1-6 Thursday Dec. 4th.
How to start Visual Studio 2008 or 2010 (command-line program)
C++ Programming: Basic Elements of C++.
C Programming Lecture 5 : Basic standard I/O Lecture notes : courtesy of Ohio Supercomputing Center, science and technolgy support.
Type Conversions Implicit Conversion Explicit Conversion.
Control Structures (B) Topics to cover here: Sequencing in C++ language.
Basics of Most C++ Programs // Programmer: Clayton Price date: 9/4/ // File: fahr2celc.cpp 03. // Purpose:
Homework #2: Functions and Arrays By J. H. Wang Mar. 20, 2012.
Project 3: Ticket Printer
Homework #2: Functions and Arrays By J. H. Wang Mar. 24, 2014.
11/10/2016CS150 Introduction to Computer Science 1 Last Time  We covered “for” loops.
Programming Fundamentals with C++1 Chapter 3 COMPLETING THE BASICS.
Data Types and Conversions, Input from the Keyboard CS303E: Elements of Computers and Programming.
Operating System Discussion Section. The Basics of C Reference: Lecture note 2 and 3 notes.html.
Data Types and Conversions, Input from the Keyboard If you can't write it down in English, you can't code it. -- Peter Halpern If you lie to the computer,
1 CS 1430: Programming in C++. 2 Input: Input ends with -1 Sentinel-Controlled Loop Input: Input begins with.
Exercise 1 #include int main() { printf(“Hello C Programming!\n”); return 0; } 1.Run your Visual Studio 2008 or Create a new “project” and add.
1 Project 2: Using Variables and Expressions. 222 Project 2 Overview For this project you will work with three programs Circle Paint Ideal_Weight What.
1 Project 3 String Methods. Project 3: String Methods Write a program to do the following string manipulations: Prompt the user to enter a phrase and.
Introduction Chapter 1 1/22/16. Check zyBooks Completion Click on the boxes for each section.
Introduction to Programming
Homework 1 (due:April 10th) Deadline : April 10th 11:59pm Where to submit? eClass 과제방 ( How to submit? Create a folder. The name.
Literals A literal (sometimes called a constant) is a symbol which evaluates to itself, i.e., it is what it appears to be. Examples: 5 int literal
1 Project 5: Leap Years. 222 Leap Years Write a program that reads an integer value from the user representing a year and determines if the year is a.
1 Project 4: Computing Distance. 222 Computing Distance Write a program to compute the distance between two points. Recall that the distance between the.
Homework 2 (due:April 17th) Deadline : April 17th 11:59pm Where to submit? eClass “ 과제방 ” ( How to submit? Create a folder. The.
Course A201: Introduction to Programming 09/09/2010.
NOTE: C programs consist of functions one of which must be main. C programs consist of functions one of which must be main. Every C program begins executing.
Homework 1 (due:April 13th) Deadline : April 13th 11:59pm Where to submit? eClass 과제방 ( How to submit? Create a folder. The name.
Input, Output and Variables GCSE Computer Science – Python.
Introduction to Programming
Homework 3 (due:May 27th) Deadline : May 27th 11:59pm
Data Types and Conversions, Input from the Keyboard
TEMPERATURE CONVERSION
Variables, Expressions, and IO
Homework 3 (due:June 5th)
CS 1430: Programming in C++ Turn in your Quiz1-2 No time to cover HiC.
Python I/O.
CSCE 206 Lab Structured Programming in C
HOMEWORK: Formulas Worksheet
Introduction to Programming
Suppose I want to add all the even integers from 1 to 100 (inclusive)
PLC 5 and ControlLogix Subroutine Parameters
Programming in JavaScript
Programming in JavaScript
Introduction to C Programming
Homework 2 (due:May 15th) Deadline : May 15th 11:59pm
Homework 1 (due:April 17th)
Homework 2 (due:May 5th) Deadline : May 5th 11:59pm
Unit 3: Variables in Java
Introduction to Programming
National Chiao Tung University
Data Types and Maths Programming Guides.
CSCE 206 Lab Structured Programming in C
CSCE 206 Lab Structured Programming in C
Homework 2 (due:May 13th) Deadline : May 11th 11:59pm
CS 11 – April 1 Review steps for lab #3
Introduction Worksheet
Presentation transcript:

Homework 1 (due:April 8th) Deadline : April 8th 11:59pm Where to submit? eClass “ 과제방 ” ( How to submit? Create a folder. The name of the folder should be “studentID#.hw1”. (ex) hw1 We have three problems in hw1. Make three C source files. The name of the source files should be the format “studentID#.hw1.#.c” (ex) hw1.1.c, hw1.2.c, hw1.3.c In each source file.c, your code must have comments that include your name and student_id# Put the three source files into the folder we created. Compress the folder into a zip file. The name of the zip file should be “student#.hw1.zip”. (ex) hw1.zip Upload the zip file into eClass website. If you don’t follow above instructions, you may get penalty in your score. You must do programming yourself.

1. Write a program that reads a five digit integer and prints the sum of its digits as an output. #include int main() { int five_digit_num; // you may declare variables here scanf(“%d”,&five_digit_num); // put your code here return 0; } Input example 22 output example

#include int main() { float celcius, fahrenheit; // put your code here return 0; } 2. Write a program that converts the temperature from a Celcius degree into Fahrenheit degree. The conversion equation : Fahrenheit = Celcius * Output Example : celcius degree ? 10.7 (  --- keyboard user input) Fahrenheit degree =

3. Write a program that converts meter-type height into [feet(integer),inch(float)]-type height. Your program should get one float typed height value as an input and prints integer typed feet value and the rest of the height is represented as inch type. (1m=3.2808ft=39.37inch) (Input example) 1.80 (output example) 5feet 10.9inch