Lesson 4 of 34
Operators: கணக்கீடுகள்
8 min 20 XP
Java-ல் + - * / % operators உள்ளன. கவனம்: இரண்டு int-களை வகுத்தால் (/) விடை முழு எண் மட்டுமே, தசமப் பகுதி நீக்கப்படும். % மீதியை (remainder) தரும்.
Example: edit me and press Run
Output Loading Java (first time takes a few seconds)
Press Run to see the result here.தசம விடை வேண்டுமெனில் (double) என்று cast செய்யுங்கள். x += 5 என்பது x = x + 5 என்பதன் சுருக்கம். x++ ஒன்றைக் கூட்டும், x-- ஒன்றைக் குறைக்கும்.
Example: edit me and press Run
Output Loading Java (first time takes a few seconds)
Press Run to see the result here.printf("%.2f%n", value) இரண்டு தசம இடங்களுடன் print செய்யும். %n என்பது புதிய வரி.