0
Why is it relevant to understand how many bytes are in a variable
Counting Bytes
2 Respostas
+ 1
Because variable types store finite amounts data. Sometimes you may require more storage for your calculation.
+ 1
1)This is useful if you want to optimize your program for a system with limited memory. You would then choose types with just the size required.
2)If a variable is defined with the wrong type and is too small to hold a value , the program will fail or have unexpected behaviour. this knowledge can help troubleshootand / avoid those issues.