Create a free account on Computer Sir Ki Class and unlock access to valuable learning resources.
Exam Paper Downloads: After registering and logging in, you can download exam question papers in PDF format to practice and prepare for your exams.
Student Support: Get assistance with your doubts, queries, and questions related to your studies. Our support is here to help you understand topics and resolve your learning difficulties.
Register today and make your exam preparation easier and more effective!
Why do we add f suffix to a decimal literal number when we initialise a float variable.
Solution
TC++ #3880
×
Ask AI About This Code
Default Prompt that is passed along with the code is given below, You can write your own prompt if you so desire.
×
Test Java
The code has been copied automatically for you in the clipboard. After that open any of the service and press cntrl-v to paste in the given code area. Needs a bit of tweaking as per the link.
By default any decimal number like 23.34 would be assumed to be a double number. by adding f suffix like 23.34f we tell the compiler to reserver on 32 bits for the given number as against the use of 64 bits it would have done if we do not add the suffix.