Lesson 4 of 34

input(): ಬಳಕೆದಾರರನ್ನು ಕೇಳುವುದು

8 min 20 XP

ಬಳಕೆದಾರರು ಟೈಪ್ ಮಾಡಿದ್ದನ್ನು input() ಓದುತ್ತದೆ. ಇಲ್ಲಿ Run ಒತ್ತುವ ಮೊದಲು Input box ನಲ್ಲಿ ಮೌಲ್ಯಗಳನ್ನು ಟೈಪ್ ಮಾಡಿ, ಸಾಲಿಗೆ ಒಂದು.

Example: edit me and press Run

Output Loading Python (first time takes a few seconds)
Press Run to see the result here.

input() ಯಾವಾಗಲೂ string ಕೊಡುತ್ತದೆ. ಸಂಖ್ಯೆಯಾಗಿ ಬಳಸಲು int(input()) ಎಂದು ಬರೆಯಿರಿ.

Example: edit me and press Run

Output Loading Python (first time takes a few seconds)
Press Run to see the result here.

ಪ್ರತಿ input() Input box ನ ಮುಂದಿನ ಸಾಲನ್ನು ಓದುತ್ತದೆ.

Challenge

+20 XP

input() ಬಳಸಿ ಎರಡು ಸಂಖ್ಯೆಗಳನ್ನು ಓದಿ, ಅವುಗಳ ಮೊತ್ತವನ್ನು print ಮಾಡಿ. Input box ನಲ್ಲಿ 5 ಮತ್ತು 7 ಇವೆ, ಆದ್ದರಿಂದ ಉತ್ತರ 12 ಆಗಬೇಕು.

Output Loading Python (first time takes a few seconds)
Press Run to see the result here.