Русские видео

Сейчас в тренде

Иностранные видео


Скачать с ютуб Nearest multiple of 10 | GeeksForGeeks | Problem of the Day в хорошем качестве

Nearest multiple of 10 | GeeksForGeeks | Problem of the Day 2 дня назад


Если кнопки скачивания не загрузились НАЖМИТЕ ЗДЕСЬ или обновите страницу
Если возникают проблемы со скачиванием, пожалуйста напишите в поддержку по адресу внизу страницы.
Спасибо за использование сервиса savevideohd.ru



Nearest multiple of 10 | GeeksForGeeks | Problem of the Day

A string str is given to represent a positive number. The task is to round str to the nearest multiple of 10. If you have two multiples equally apart from str, choose the smallest element among them. Examples: Input: str = 29 Output: 30 Explanation: Close multiples are 20 and 30, and 30 is the nearest to 29. Input: str = 15 Output: 10 Explanation: 10 and 20 are equally distant multiples from 20. The smallest of the two is 10. Expected Time Complexity: O(n). Expected Auxiliary Space: O(1). #geeksforgeeks #problemoftheday #education #computerscience #coding #array #sorting #sorts #sort #datastructure #algorithmicproblemsolving #algorithms #algorithm #dynamicprogramming #dp #potd #gfg #binarytree #binarysearchtree #bst #string #dictionary #python #stack #queue #python #c++ #interview Table of Contents 0:00 Problem Statement 0:44 Solution 4:20 Pseudo Code 7:21 Pseudo Code Explanation 10:44 Code - Python 12:17 Code - C++

Comments