Multiple choice question on c programming

Assignment Help C/C++ Programming
Reference no: EM13161612

  1. Create a function to print "88 is a great port number"
    • function name is yourName_PrintFunction
    • no input
    • no return type
    • print "88 is a great port number"
  2. create a function to print a float
    • function name is yourName_PrintFloat
    • input parameter is a float
    • no return type
    • print the float input parameter
  3. create a function to square a value
    • function name is yourName_SquareValue
    • input parameter is a int
    • return type is an int
    • you will multiply the input int with the input int (int X int) and return this value
  4. create a function to add two number together
    • function name is yourName_AddValues
    • input parameter is an int (pass by value)
    • input parameter is a pointer to a int (pass by reference)
    • add the value input parameter to the reference input parameter
  5. create a function to print the values of an array
    • function name is yourName_PrintArray
    • input parameter is an int array
    • input parameter is the size of the array
    • create a for loop or while loop to print each element of the array
  6. Main function
    • declare and initialize a float variable to have the value .88
      • name the float variable yourName_floatEightyEight
    • declare a int variable
      • name the int variable yourName_firstInt
    • declare an int variable
      • name the int variable yourName_secondInt
      • initialize yourName_secondInt to be 8
    • call the function yourName_PrintFunction
    • call the function yourName_PrintFloat
      • pass in the yourName_floatEightyEight variable
    • call the function yourName_SquareValue
      • pass in the value 88
      • save the return value to the variable yourName_firstInt
    • call the function yourName_addValues
      • the value input parameter will be yourName_firstInt
      • the reference input parameter will be yourName_secondInt (pointer)
    • declare and initialize a int array of int values from 0 - 10
      • name the int array yourName_intArray
    • call the function yourName_PrintArray
      • pass in the yourName_intArray
      • pass in the size of the array
  7. Move the function yourName_PrintFunction into a separate file

 

 

Reference no: EM13161612

Questions Cloud

Create the class airplane : Your missions is to create the class Airplane. Each Airplane object should store the following information (fields):
How the differences in chromosome between chimps and humans : What can you say about the relationship between chimp and human chromosomes? Explain how the differences in chromosome number between chimps and humans represented an opportunity to test a prediction of common ancestry?
Depict the lewis structure of tartaric and malic acids : Draw the Lewis structure of tartaric and malic acids in a way that shows the geometry of the acid functional groups. Indicate the hybridization of each carbon
What is the marginal opportunity cost : Given the above prices, will the firm adopt a new method which involves 10 units of land, 3 of labor, 2 of capital, and 2 of entrepreneurial ability?
Multiple choice question on c programming : Create a function to print "88 is a great port number" function name is yourName_PrintFunction no input no return type print "88 is a great port number"
Draw a bidirectional replication fork : Draw a bidirectional replication fork and label the origin of replication, the leading strands, lagging strands, and the 5' and 3' ends of all strands shown in your diagram.
What is the difference between covalent bonds : What is the difference between covalent bonds, hydrogen bonds, van der waals interactions and ionic bonds?
Multiplexor and demultiplexor? : statistical time division multiplexing with 24 stations inputting data at 9600 bps, and assuming that only 60 percent of those stations transmit at one time, what is the minimal speed necessary for the high speed link connecting multiplexor and demul..
Each salesperson passes : Thus, each salesperson passes between 0 and 5 slips per day. Assume that the information from all of the slips from last month are available. Write an app that will read all the information for last months sales and summarize the total sales by sales..

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Properly store the number from variable value

1. Statement will properly store the number from variable  value  into the output file object AnsFile?

  Pros and cons of choosing two servers

Classify the two alternatives in terms of what type of application architecture they use. b. Outline the pros and cons of the two alternatives and make a recommendation to Fred about which is better.

  Write program which inputs number of winning coupons

Write a program which inputs number of coupons you win and outputs how many candy bars and gumballs you can get if you spend all off your coupons on candy bars first and remaining coupons on gumballs in c++.

  Write a complete c++ program

The main program will read in a parameter value n (read this in main). Then it will call a function read2arrays (details below) to read lists of grades into two arrays, which the main program will call test1 and test2 (or some other names of your ..

  Write a program in c that will find smallest value

Write a programe c that will find the smallest, largest and average values in a collection of N numbers.Get the value of N before scanning each value in the collection of N numbers.

  Asks the user for the name of an input file and translates

Write a C++ program that asks the user for the name of an input file and translates the contents of that input file using ROT13. Your  main  function should be responsible for reading the input file and coordinating calls to a value-returning functio..

  Prepare a program that uses the pthread library

Prepare a C/C++ program that uses the PTHREAD library to create threads and mutexes to synchronize them.

  Write a program to read a data file and extract parameters

Write a C/C++ program to read a data file and extract parameters. The program must obtain the filename via a command-line argument.

  Write a program to crypt its input accordingly

Write a program to crypt its input according to a specified transformation scheme

  Multidimensional arrays

multidimensional arrays to life, let's consider a specific example: How can you visualize a 4-dimensional array? How can you give meaning to each dimension this array has? What kind of application would such an array be useful for?

  Draw the heap

Eric Rowe Starting with an empty minheap, draw the heap after each the completion of the following operations  and repeat for a maxheap (replace removeMin() with removeMax()). Upload your drawings here. Hand drawn is fine:

  Write c program to find smallest-largest values

Write a program c that will find the smallest, largest and average values in a collection of N numbers.Get the value of N before scanning each value in the collection of N numbers.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd