Решить задачу прошу новичок | Sololearn: Learn to code for FREE!
¡Nuevo curso! ¡Todo programador debería aprender IA Generativa!
Prueba una lección gratuita
0

Решить задачу прошу новичок

Наступне число 2 Для заданого цілого числа n знайдіть число, наступне за n, кратне 10. Вхідні дані Одне ціле число n. Вихідні дані Вивести число, наступне за n, кратне 10. Ліміт часу 1 секунда Ліміт використання пам'яті 128 MiB Вхідні дані #1 7 Вихідні дані #1 10 Вхідні дані #2 -5 Вихідні дані #2 0

12th Oct 2020, 9:37 AM
Masha [MK]
Masha [MK] - avatar
7 Respuestas
+ 2
Can you write your Question in english language here mostly peoples know english
12th Oct 2020, 10:30 AM
A S Raghuvanshi
A S Raghuvanshi - avatar
+ 2
🇮🇳Vivek🇮🇳 Mr . Am not forcing understood noone have time to translate . Noone have time to do other homework read rules before posting any questions.
12th Oct 2020, 12:15 PM
A S Raghuvanshi
A S Raghuvanshi - avatar
+ 1
Ответ внесу кодом но сначала переведу: As asked: Help me find a solution The task: Find a number multiplied by 10 that is nearest and bigger than input Ex: Input 7 Output 10 Input -5 Output 0 Python: ask=int(input()) print((abs(ask)+10-(int(abs(ask)%10))+(int(abs(ask)/ask)-1)*5)*int(abs(ask)/ask))
12th Oct 2020, 11:34 AM
Alex Vernee
Alex Vernee - avatar
+ 1
x = 11 if x%10!=0: krat = (x // 10)+1 else: krat = int(x/10) print(x, krat)
12th Oct 2020, 12:05 PM
Shadoff
Shadoff - avatar
+ 1
♨️♨️ please don't force anyone to ask in English. You can use Google translator. Here is translation I am asking a beginner to solve the problem The next number is 2 For a given integer n, find the number following n that is a multiple of 10. Incoming data One integer n. Output data Print the number following n, a multiple of 10. Time limit 1 second Memory usage limit 128 MiB Input # 1 7 Output # 1 10 Input # 2 -5 Source data # 2 0
12th Oct 2020, 12:06 PM
🇮🇳Vivek🇮🇳
🇮🇳Vivek🇮🇳 - avatar
0
♨️♨️ di di, I am just saying. Not to force anyone to ask in English. Because he/she may be not comfortable with English. I know on sololearn most people know English. But there people who know only their local languages. If someone ask questions in their local languages. It will be possible for him/her to get answers in that language. Yes, it is against rules to post homework. We should say him/her to read guidelines before asking questions.
12th Oct 2020, 12:24 PM
🇮🇳Vivek🇮🇳
🇮🇳Vivek🇮🇳 - avatar
0
Привіт! Знаю, що уже пройшло 3 роки і я занадто пізно відповім, але раптом новачки в Python стикнуться із такою задачею. Ось розв'язок: a=int(input()) print((a//10+1)*10) Hi! I know about 3 years old have already passed, but suddenly newbies in learning Python faced with this task. The Answer there: a=int(input()) print((a//10+1)*10) Дякую за увагу! Thx for the attention!
13th Mar 2023, 7:44 PM
DanyloLyk