Lesson 3 of 24
cin आणि getline ने Input
8 min 20 XP
cin >> x space किंवा नवीन ओळीपर्यंत एक value वाचतो. Spaces असलेल्या संपूर्ण ओळीसाठी getline(cin, s) वापरा. cin >> नंतर getline पूर्वी उरलेला newline वगळण्यासाठी cin.ignore() call करा.
Example: edit me and press Run
Output Loading C++ (first time takes a few seconds)
Press Run to see the result here.