pyuser@deyu:~/zzz$ python Python 3.12.9 (main, Aug 14 2025, 00:00:00) [GCC 14.2.1 20250110 (Red Hat 14.2.1-7)] on linux Type "help", "copyright", "credits" or "license" for more information. >>> x=5.0 >>> y=int(x)+2 >>> print(y,type(y)) 7 <class 'int'>
>>> x=5 >>> y=float(x)+2 >>> print(y,type(y)) 7.0 <class 'float'> >>> quit()