Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I need help with the following questions 1.Write a program that accepts 3 integers, a, b, and c, calculates and prints the followings i) a

I need help with the following questions image text in transcribed
1.Write a program that accepts 3 integers, a, b, and c, calculates and prints the followings i) a "bitwise or" with "complement of" b ii) (b "inclusive or with" c) "or" a iii) a "bitwise and" with "complement of" a 2) Write a program to print the values between 1 and 200 that are divisible by 2 and 3 3) Write a program to accept an unsigned integer and calculates the number of I's in its binary representation. 4) We can calculate the distance traveled by an object using distance-velocity x time. Calculate the total distance traveled for speeds (in units of speed/unit of time) in the interval [40,60] in steps of 2 for each time (in unit of time) in the interval [10, 50] in steps of 5) What is the output of the following program and WHY? #include int mainO int x = 2; switch (x) case 1: printf("Choice is 1n"); case 2: printf("Choice is 21n"); case 3: printf("Choice is 3 n"); case 4: printf"Choice is 4ln"); break break printf("After Switch"); default: printf("Choice other than 1, 2, 3 and 4n"); return 0; 6) If a-98 (decimal), b=0x1a83 (hexadecimal), and c-v7340| (octal), calculate the following i) a & b ii) blc ii (alcb iv) (c)&a

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions