Write a program whose inputs are three integers, and whose output is the smallest of the three values. Ex: If the input is: 7 15 3 the output is: 3 4806761279990437
Operations
In mathematics and computer science, an operation is an event that is carried out to satisfy a given task. Basic operations of a computer system are input, processing, output, storage, and control.
Basic Operators
An operator is a symbol that indicates an operation to be performed. We are familiar with operators in mathematics; operators used in computer programming are—in many ways—similar to mathematical operators.
Division Operator
We all learnt about division—and the division operator—in school. You probably know of both these symbols as representing division:
Modulus Operator
Modulus can be represented either as (mod or modulo) in computing operation. Modulus comes under arithmetic operations. Any number or variable which produces absolute value is modulus functionality. Magnitude of any function is totally changed by modulo operator as it changes even negative value to positive.
Operators
In the realm of programming, operators refer to the symbols that perform some function. They are tasked with instructing the compiler on the type of action that needs to be performed on the values passed as operands. Operators can be used in mathematical formulas and equations. In programming languages like Python, C, and Java, a variety of operators are defined.
Need help, C
![**3.21 LAB: Smallest Number**
In this lab, you will write a program whose inputs are three integers, and whose output is the smallest of the three values.
### Example
If the input is:
```
7 15 3
```
The output should be:
```
3
```
---
**Lab Activity Details**
**3.21.1: LAB: Smallest number**
**Score: 0 / 10**
Using the C Programming Language, open the "main.c" file and follow the instructions below:
```c
#include <stdio.h>
int main(void) {
/* Type your code here. */
return 0;
}
```
### Steps to Complete the Lab:
1. Write a C program that reads three integers from the input.
2. Compare the three integers to determine the smallest one.
3. Print the smallest integer.
### Coding Environment
- **Develop mode**: Allows you to write and test your code.
- **Submit mode**: Allows you to submit your final version of the code for grading.
**Note:**
- Run your program as often as you'd like, before submitting for grading. Below, type any needed input values in the first box, then click 'Run program' and observe the program's output in the second box.
### Hints:
- Use a combination of if-else statements or conditional (ternary) operators to determine the smallest number.
- Make sure to test your code with different sets of input values to verify accuracy.](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F3e035166-c990-4dd0-a7c5-b2c139b07c7d%2F1c901752-7ad9-4e5e-8f2d-a5907413022c%2Fg41vrr_processed.png&w=3840&q=75)
![](/static/compass_v2/shared-icons/check-mark.png)
Trending now
This is a popular solution!
Step by step
Solved in 4 steps with 2 images
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![C How to Program (8th Edition)](https://www.bartleby.com/isbn_cover_images/9780133976892/9780133976892_smallCoverImage.gif)
![Database Systems: Design, Implementation, & Manag…](https://www.bartleby.com/isbn_cover_images/9781337627900/9781337627900_smallCoverImage.gif)
![Programmable Logic Controllers](https://www.bartleby.com/isbn_cover_images/9780073373843/9780073373843_smallCoverImage.gif)