Python1423 백준 28074 모비스 https://www.acmicpc.net/problem/28074 28074번: 모비스 주어진 문자열에 포함된 알파벳 대문자들을 이용해 MOBIS를 만들 수 있으면 "YES", 그렇지 않으면 "NO"를 출력한다. www.acmicpc.net 1 2 3 4 5 6 7 8 9 10 11 12 13 14 def solution(s): answer = False if 'M' in s and 'O' in s and 'B' in s and 'I' in s and 'S' in s: answer = True if answer: return 'YES' else: return 'NO' if __name__ == '__main__': s = input() print(solution(s)) Colored by Color S.. 2023. 6. 8. 백준 28097 모범생 포닉스 https://www.acmicpc.net/problem/28097 28097번: 모범생 포닉스 모두가 알다시피, 포닉스는 포스텍을 대표하는 모범생이다! 포닉스는 최고의 모범생답게 남들과는 다른 공부 계획표를 가지고 있다. 포닉스는 총 $N$개의 공부 계획을 가지고 있다. $i$번째 공부 www.acmicpc.net 1 2 3 4 5 6 7 8 9 10 11 def solution(n, t): total = sum(t) + (n - 1) * 8 day, hour = total // 24, total % 24 return day, hour if __name__ == '__main__': n = int(input()) t = map(int, input().split()) print(*solution(n, t.. 2023. 6. 8. 백준 27890 특별한 작은 분수 https://www.acmicpc.net/problem/27890 27890번: 특별한 작은 분수 첫 번째 줄에 $0$초에서의 분수의 높이 $x_0$와 $N$이 주어진다. $x_0$와 $N$은 모두 정수이다. www.acmicpc.net 1 2 3 4 5 6 7 8 9 10 11 12 13 def solution(x, n): for i in range(n): if x % 2 == 0: x = int(x / 2) ^ 6 else: x = (2 * x) ^ 6 return x if __name__ == '__main__': x, n = map(int, input().split()) print(solution(x, n)) Colored by Color Scripter cs 2023. 6. 8. 백준 28113 정보섬의 대중교통 https://www.acmicpc.net/problem/28113 28113번: 정보섬의 대중교통 버스에 더 먼저 탑승할 수 있으면 Bus, 지하철에 더 먼저 탑승할 수 있으면 Subway, 버스와 지하철에 탑승하게 되는 시간이 동일하면 Anything을 출력한다. www.acmicpc.net 1 2 3 4 5 6 7 8 9 10 11 12 13 def solution(n, a, b): if a == b: return 'Anything' elif a 2023. 6. 7. leetcode 2652. Sum Multiples https://leetcode.com/problems/sum-multiples/description/ Sum Multiples - LeetCode Can you solve this real interview question? Sum Multiples - Given a positive integer n, find the sum of all integers in the range [1, n] inclusive that are divisible by 3, 5, or 7. Return an integer denoting the sum of all numbers in the given range satisf leetcode.com 1 2 3 4 5 6 7 8 class Solution(object): def su.. 2023. 5. 16. Google Analytics Data API과 Python을 활용한 데이터 수집(Data collection using Google Analytics Data API and Python) https://developers.google.com/analytics/devguides/reporting/data/v1/quickstart-client-libraries?hl=en#python developers.google.com 위 링크의 내용을 따라 진행하시면 되고 (영어로!) Step 2 내용은 내려받은 json 파일에서 client_email에 해당하는 부분을 사용하시면 됩니다. You can proceed by following the link above. For Step 2, use the part corresponding to client_email in the downloaded json file. 13300685251740183869 | Google Analytics Data API .. 2023. 5. 11. 백준 27959 초코바 https://www.acmicpc.net/problem/27959 27959번: 초코바 밤고는 $100$원 동전을 $N$개 갖고 있고, 그 돈으로 가격이 $M$원인 초코바를 사 먹으려고 한다. 밤고는 갖고 있는 돈으로 초코바를 사 먹을 수 있는지 알고 싶어 한다. 밤고가 가진 돈이 초코바의 www.acmicpc.net 1 2 3 4 5 6 7 8 9 10 11 dddddef sol(n, m): if n * 100 >= m: return 'Yes' else: return 'No' if __name__ == '__main__': n, m = map(int, input().split()) print(sol(n, m)) Colored by Color Scripter cs 2023. 4. 25. leetcode 1431. Kids With the Greatest Number of Candies https://leetcode.com/problems/kids-with-the-greatest-number-of-candies/description/ Kids With the Greatest Number of Candies - LeetCode Can you solve this real interview question? Kids With the Greatest Number of Candies - There are n kids with candies. You are given an integer array candies, where each candies[i] represents the number of candies the ith kid has, and an integer extraCandie leetc.. 2023. 4. 17. 백준 27889 특별한 학교 이름 https://www.acmicpc.net/problem/27889 27889번: 특별한 학교 이름 GEC에는 여러 학교가 있다. 각 학교의 약칭과 정식 명칭은 다음과 같다. NLCS: North London Collegiate School BHA: Branksome Hall Asia KIS: Korea International School SJA: St. Johnsbury Academy 학교 이름을 좋아하는 규빈이 www.acmicpc.net 1 2 3 4 5 6 7 8 9 10 11 12 13 14 def sol(s): name = { 'NLCS':'North London Collegiate School', 'BHA': 'Branksome Hall Asia', 'KIS': 'Korea Internat.. 2023. 4. 4. leetcode 2348. Number of Zero-Filled Subarrays https://leetcode.com/problems/number-of-zero-filled-subarrays/description/ Number of Zero-Filled Subarrays - LeetCode Can you solve this real interview question? Number of Zero-Filled Subarrays - Given an integer array nums, return the number of subarrays filled with 0. A subarray is a contiguous non-empty sequence of elements within an array. Example 1: Input: nums = leetcode.com 1 2 3 4 5 6 7 .. 2023. 3. 21. leetcode 1009. Complement of Base 10 Integer https://leetcode.com/problems/complement-of-base-10-integer/description/ Complement of Base 10 Integer - LeetCode Can you solve this real interview question? Complement of Base 10 Integer - The complement of an integer is the integer you get when you flip all the 0's to 1's and all the 1's to 0's in its binary representation. * For example, The integer 5 is "101" in b leetcode.com 1 2 3 4 5 6 7 .. 2023. 3. 20. leetcode 2553. Separate the Digits in an Array https://leetcode.com/problems/separate-the-digits-in-an-array/description/ Separate the Digits in an Array - LeetCode Can you solve this real interview question? Separate the Digits in an Array - Given an array of positive integers nums, return an array answer that consists of the digits of each integer in nums after separating them in the same order they appear in nums. leetcode.com 1 2 3 4 5 6.. 2023. 3. 14. 이전 1 ··· 11 12 13 14 15 16 17 ··· 119 다음