Author Archives: Mitzi Hernandez

#WSQ10 #TC1017

 

Create a program that asks the user for 10 numbers  (floating point). Store those numbers in a list. Show to the user the total, average and standard deviation of those numbers.(To this program, I needed help of my classmate Pablo Guerra)

 

 

 

 

 

 

 

 

#WSQ09 #TC1017

Create a program that asks the user for a non-negative integer (let’s call that number n) and display for them the value of n! (n factorial). After showing them the answer, ask them if they would like to try another number (with a simple y/n response) and either ask again (for y) or quit the program and wish them a nice day (if they answered n).

RECURSION

#mastery04 #TC1017

#mastery20 #TC1017

#mastery19 #TC1017

#mastery12 #TC1017

#mastery10 #TC1017

#mastery18 #TC1017

We say that a conditional structure is nested when the branch of true or false in a conditional structure is another conditional structure. for example:

#mastery18 #TC1017

The flow chart is presented contains two conditional structures. The principal is a conditional composite structure and the second is a simple conditional structure and is contained by the false branch of the first structure.

It is common for even more complex nested conditional structures arise.

in c ++ have another format, we will see later in our wsq.

#mastery17 #TC1017

It’s called switch to a variable that takes only two values, which are identified with the “open / closed”, “true / false”, “on / off”, “start / stop”, “valid / invalid”, etc.

 

The switch is used to control and program flow for decision making. For its bipolar nature resemble Boolean variables, occurring many times that the switch is a boolean variable. However, not all switches are Boolean variables or all variables are boolean switches.

A switch normally be replaced by an evaluation of a variable. However, they are widely used because they avoid having to evaluate complex expressions and because they provide clarity for writing and reading programs.

#mastery09 #TC1017

Compilers reserve certain terms or keywords (keywords) for the syntactic language use, such as: asm, auto, break, case, char, do, for, etc. While these words are defined for ANSI C, different compilers extend this definition to other terms.

To create a variable in a particular place of a program first write the variable and then the identifier with which we name the variable, followed all a ‘;’. This is referred to define a variable. The general definition is:

 

For example:

 

int number; / * Create the variable number of type integer * /

char letter; / * Create the letter variable, character type * /

float a, b; / * Create two variables a and b, of floating point number * /