how to take input of double number in c++ | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

how to take input of double number in c++

to take all number after the decimal

12th Jun 2020, 8:34 AM
GAURAV SINGH
GAURAV SINGH - avatar
2 Answers
0
double n; cin>>n; so you can take decimal input
12th Jun 2020, 8:35 AM
꧁༒☬Bad☬Boy☬༒꧂
꧁༒☬Bad☬Boy☬༒꧂ - avatar
0
no it not take all digit after the decimal  for ex double n=14049.30493; cout<<n; output 14049.3
12th Jun 2020, 8:56 AM
GAURAV SINGH
GAURAV SINGH - avatar