Programming in C
Programming in C
4th Edition
ISBN: 9780321776419
Author: Stephen G. Kochan
Publisher: Addison-Wesley
Expert Solution & Answer
Book Icon
Chapter 3, Problem 8E

Explanation of Solution

Program:

The following program will round off the value to the next largest even multiple of another value:

//include the header file

#include <stdio.h>

//definition of main method

int main (void)

{

//declare the variables

int i, j, ans;

//get the inputs from the user

printf("Enter the value to round off: ");

scanf("%d", &i);

printf ("Enter the value to make i divisible of...

Blurred answer
Students have asked these similar questions
let n = 1*3*5*....*197*199 (the product of first 100 odd numbers)   find the last 2 digits of n
Suppose n is a positive integer.
Please calculate the multiplication series of 8 matrices: A*B*C*D*E*F*G*H The dimensions are: 32x35, 35x24, 24x30, 30x36, 36x25, 25x40, 40x34, 34x35 What is the best order to multiply them? Please use parentheses to express the multiplication order, such as (((AB)(CD))((EF)(GH))) How many multiplications are required in total?
Knowledge Booster
Background pattern image
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
C++ Programming: From Problem Analysis to Program...
Computer Science
ISBN:9781337102087
Author:D. S. Malik
Publisher:Cengage Learning
Text book image
EBK JAVA PROGRAMMING
Computer Science
ISBN:9781337671385
Author:FARRELL
Publisher:CENGAGE LEARNING - CONSIGNMENT