Submission #19674400


Source Code Expand

Copy
# -*- coding: utf-8 -*-
"""
Created on Sun Jan 24 19:33:54 2021

@author: hp
"""
def power(a,b):
    res=1
    while b>0:
        if (b&1):
            res=res*a
        b>>=1
        a=a*a
    return res

n,m=map(int,input().strip().split())
#print(n,m)
ans=(power(10,n)/m)%m
print(int(ans))

Submission Info

Submission Time
Task A - Simple Math 2
User whix
Language Python (3.8.2)
Score 0
Code Size 312 Byte
Status TLE
Exec Time 2206 ms
Memory 18988 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 0 / 300
Status
AC × 2
TLE × 1
AC × 2
TLE × 21
Set Name Test Cases
Sample example_00, example_01, example_02
All example_00, example_01, example_02, max_random_00, max_random_01, max_random_02, max_random_03, max_random_04, small_m_00, small_m_01, small_m_02, small_m_03, small_m_04, small_m_05, small_m_06, small_m_07, small_m_08, small_m_09, special_00, special_01, special_02, special_03, special_04
Case Name Status Exec Time Memory
example_00 AC 29 ms 8948 KB
example_01 AC 25 ms 8840 KB
example_02 TLE 2206 ms 16756 KB
max_random_00 TLE 2206 ms 17356 KB
max_random_01 TLE 2206 ms 15872 KB
max_random_02 TLE 2206 ms 17452 KB
max_random_03 TLE 2206 ms 16632 KB
max_random_04 TLE 2206 ms 17232 KB
small_m_00 TLE 2206 ms 17392 KB
small_m_01 TLE 2206 ms 15720 KB
small_m_02 TLE 2206 ms 17544 KB
small_m_03 TLE 2206 ms 16744 KB
small_m_04 TLE 2206 ms 17124 KB
small_m_05 TLE 2206 ms 18988 KB
small_m_06 TLE 2206 ms 17008 KB
small_m_07 TLE 2206 ms 17172 KB
small_m_08 TLE 2206 ms 17176 KB
small_m_09 TLE 2206 ms 16552 KB
special_00 TLE 2206 ms 17120 KB
special_01 TLE 2206 ms 15720 KB
special_02 TLE 2206 ms 17556 KB
special_03 TLE 2206 ms 16944 KB
special_04 TLE 2206 ms 17116 KB