help me ..convert char to in

how to convert char to int like ..
/////////Hrs/mins
00:00 = 0.0
01:00 = 1.0
08:00 = 8.0
08:01 = 8.1
17:00 = 17.0
17:30 = 17.0

can you say to me the formula of this..

ex. if i enter time in like //char--> 08:10 ...automatically convert it on int like 8.10

TY hopefully help me with my problem
Last edited on
closed account (o3hC5Di1)
Hi there,

Please note that numbers containing a floating point (also called comma in some languages) are not integers - they are floating point values. In C++ there are two floating point datatypes: float and double.

I'm assuming that's what you need. The same question was asked recently, so I would sugegst you have a look at the answers there: http://www.cplusplus.com/forum/beginner/112388/

Please do let us know if you require any further help.

All the best,
NwN

nobodyownz is my classmate :D he explain to me that but i cant understand :D


if have other types of conversion of char to int pls say it to me :D
Topic archived. No new replies allowed.