Write a c program to input three real numbers, C/C++ Programming

Assignment Help:

 Write a C program to input three real numbers and  print them out as follows :

The first variable is ....... and the second one is ......

The last variable is ..........

The variable format specification is

Variable 1 10 spaces of 5 decimal

Variable 2   none

Variable 3  signed  10 spaces 5 decimal
   
  #include stdio.h
  main()
  {
  char prompt;

  float a,b,c;

  printf("Please enter in three real numbers \n\r");

  scanf("%f %f %f",&a,&b,&c);

printf("The first variable is%11.5f  and the second one is %f \n\r",a,b);

printf("The last variable is %+12.5f \n\r",c);

printf("Press any key to exit \n\r");

scanf("\n%c",&prompt); 
  }


Related Discussions:- Write a c program to input three real numbers

Output, i need my home work

i need my home work

Define the bitwise-exclusive-or operator, Define the Bitwise-Exclusive-OR O...

Define the Bitwise-Exclusive-OR Operator: ^: The bitwise-exclusive-OR operator (^) compares every bit of its first operand to the corresponding bit of its second operand. If on

Define the volatile keyword qualifiers in c language, Define the Volatile K...

Define the Volatile Keyword Qualifiers in C Language? The volatile keyword proceed as a data type qualifier and a volatile variable is for dynamic use. E.G. for data that is to

Implement binary heap in c++?, A:BinaryHeap.h ------------ #ifndef BI...

A:BinaryHeap.h ------------ #ifndef BINARY_HEAP_H_ #define BINARY_HEAP_H_ #include "dsexceptions.h" #include "vector.h" // BinaryHeap class // CONSTRUCTION: wi

Constructor and destructor function with derived classes, Constructor and D...

Constructor and Destructor function with derived classes If there are constructors included in the base class and the derived class, the compiler automatically calls both of th

Area under a curve, Write a program to find the area under the curve y = f(...

Write a program to find the area under the curve y = f(x) between x = a and x = b, integrate y = f(x) between the limits of a and b. The area under a curve between two points can b

C programs, 2. a) Define a structure to store roll no, name and marks of a ...

2. a) Define a structure to store roll no, name and marks of a student. b) Using the structure of Q2. a), above write a ''C'' program to create a file "student.dat". There must be

When should i use references, A: Use references when you can use, and use p...

A: Use references when you can use, and use pointers when you have to. References are generally preferred over pointers whenever you don't require "reseating". Usually this mean

Luminous and jewels, Byteland county is very famous for luminous jewels. Lu...

Byteland county is very famous for luminous jewels. Luminous jewels are used in making beautiful necklaces. A necklace consists of various luminous jewels of particular colour. Nec

Can copy constructor admit an object of the same class , Can copy construct...

Can copy constructor admit an object of the same class as parameter, rather than reference of the object?

Write Your Message!

Captcha
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