Once again you will be using your student ID for this assignment. You will write a simple C program that utilizes two functions. A main function and a called function that will perform an arithmetic operation, either addition, subtraction, or multiplication. Your main function will initialize two variables of type integer and pass these variables to the called function as arguments. The two integer values will be your 7 digit student ID split into a three digit and a four digit nteger. Example: Student ID is 1234567 your integers would be 123 & 4567 or 1234 & 567. If you D starts with a zero make your two integers three digits each. i.e. 0123456 123 and 456

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter7: User-defined Simple Data Types, Namespaces, And The String Type
Section: Chapter Questions
Problem 5SA
icon
Related questions
Question
100%

Need help coding this in C first time using this language, please 

Once again you will be using your student ID for this assignment.
You will write a simple C program that utilizes two functions. A main function and a called
function that will perform an arithmetic operation, either addition, subtraction, or multiplication.
Your main function will initialize two variables of type integer and pass these variables to the
called function as arguments.
The two integer values will be your 7 digit student ID split into a three digit and a four digit
integer.
Example: Student ID is 1234567 your integers would be 123 & 4567 or 1234 & 567. If your
ID starts with a zero make your two integers three digits each. i.e. 0123456 123 and 456
The called function will return the answer back to the main function and the main function will
then print what the answer is.
Example "The sum of my two integers is: <whatever>"
Your programs is to use TWO separate files, one for each of the functions.
Use gcc optimization level 1 and the default 64 bit machine type for your executable.
Transcribed Image Text:Once again you will be using your student ID for this assignment. You will write a simple C program that utilizes two functions. A main function and a called function that will perform an arithmetic operation, either addition, subtraction, or multiplication. Your main function will initialize two variables of type integer and pass these variables to the called function as arguments. The two integer values will be your 7 digit student ID split into a three digit and a four digit integer. Example: Student ID is 1234567 your integers would be 123 & 4567 or 1234 & 567. If your ID starts with a zero make your two integers three digits each. i.e. 0123456 123 and 456 The called function will return the answer back to the main function and the main function will then print what the answer is. Example "The sum of my two integers is: <whatever>" Your programs is to use TWO separate files, one for each of the functions. Use gcc optimization level 1 and the default 64 bit machine type for your executable.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Datatypes
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning