Process of Problem soliving

Finding Input and there types, Find output and there types.
Find the formulas ( note may be more than one)

Step through writing program:

  • Declare all input and output variables, compile
  • Get inputs from users, compile and test
  • Step through formulas one by one, compile and test
  • Output to user final, compile and test

    Visualizer to see code running.

  • Process for Creating user defined Functions

    What is return type of your function?
    What are the arguments/parameters and what are there type?
    What are you returning?
    What is formulas needed to do computation inside?

    // Prototype
    //returnType functionName(argumentType argumentName)
    int times (int a, int b);
    int main(){
    int x;
    //usage of function
    x = times(10,2);
    return 0;
    } //Defining function
    int times(int a, int b){
    return a*b;

    Always Prototype above int main and define function below int main!!!!!!