1 / 9

SEPT 29th

SEPT 29th. Using FTP to access the contents of your Z drive. Open Microsoft Internet Explorer or any browser Type the address as ftp://username@ftp.cs.odu.edu username is your CS login ID. On hitting enter, a new window pops up asking your username and password

michi
Download Presentation

SEPT 29th

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. SEPT 29th Using FTP to access the contents of your Z drive • Open Microsoft Internet Explorer or any browser • Type the address as ftp://username@ftp.cs.odu.edu • username is your CS login ID. • On hitting enter, a new window pops up asking your username • and password • Make sure your username is your CS ID • Enter your password (UNIX password or your squirrel mail • password • Click on OK • You should be able to view the contents of your Z drive. • You will not be able to edit the contents unless you copy it into • your local drive on your computer

  2. Example 1 Lets see some functions!!! Sqrt(x) …. Calculates the square root of x. Pow(x, y) calculates x^y Write a program to find the area of a square … Try out area of a cube? Tip…Did u know that u have to use #include<cmath>

  3. List of Predefined Functions

  4. Lets find the area of a square Given: Length of the square = 4 cm. Area of a square is : (length)2 Now in Programming language or C++, I use the following way to Evaluate the expression… Two methods I declare a variable ‘ L ‘ that takes the value of the length of the square Method 1 Area = L * L ; Method 2 Area = pow(L, 2); LETS DO IT!!!!

  5. CONTROL STRUCTURES Two Roads Diverged into the woods…which one should I chose? I chose basing on some condition!!!! Control structures provide alternatives to a sequential program Execution and are used to alter the sequential flow of execution. One control structure is SELECTION Expression True False Statement 1 Statement 2

  6. Logical Example Suppose that Julia Roberts is my girlfriend and I am about to go on a date with her. Well Julia does not like rain. She wants to go to the beach. But if it rains, she wants to go to the movie to watch RUNAWAY BRIDE..she claims to be acting in that…I don’t believe!! IF( Julia is in the movie) I believe her!!! IF( Weather is raining) I am not going to the beach or going to the movie OTHERWISE I am going to the beach

  7. RELATIONAL OPERATORS • == Equal to • != Not Equal to • < Less than • <= Less than or equal to > Greater than >= Greater than Equal to

  8. SELECTION STATEMENT IN C++ One way selection if(condition) { } Two Way selection if(condition) {} else {} Selection statements Multi way selection switch case

  9. Example #3

More Related