Submission #4337369
Source Code Expand
#!usr/bin/env python3 from collections import defaultdict import math import bisect import random def LI(): return list(map(int, input().split())) def II(): return int(input()) def LS(): return input().split() def S(): return input() def IIR(n): return [II() for i in range(n)] def LIR(n): return [LI() for i in range(n)] def SR(n): return [S() for i in range(n)] mod = 1000000007 # A x,y = LI() print(max(x,y)) # B ''' s = input() list = "aiueo" for i in range(len(list)): s = s.replace(list[i],"") for i in range(len(s)): print(s[i], end = "") ''' # C """ x,y,a,b,c,d = LI() print(abs((a-x)*(d-y)-(b-y)*(c-x))/2) """ # D n,m = LI() f = [[0 if i != j else 1 for j in range(n)] for i in range(n)] for i in range(m): x,y = LI() x -= 1 y -= 1 f[x][y] = 1 f[y][x] = 1 bi = [bin(i)[2:] for i in range(1,2**n)] li = [] for i in range(2**n-1): a = [] for j in range(len(bi[i])): if bi[i][len(bi[i])-1-j] == "1": a.append(j) li.append(a) ans = 0 for l in li: st = False for i in range(1,len(l)): for j in range(i): if not f[l[i]][l[j]]: st = True break if st: break if not st: ans = max(ans,len(l)) print(ans)
Submission Info
Submission Time | |
---|---|
Task | A - 正直者 |
User | dn6049949 |
Language | PyPy3 (2.4.0) |
Score | 0 |
Code Size | 1325 Byte |
Status | RE |
Exec Time | 188 ms |
Memory | 39024 KB |
Judge Result
Set Name | all | ||
---|---|---|---|
Score / Max Score | 0 / 100 | ||
Status |
|
Set Name | Test Cases |
---|---|
all | 00_sample_01.txt, 00_sample_02.txt, kensho_diff01, kensho_diff02, kensho_diff03, kensho_diff04, kensho_diff05, kensho_min-max01, kensho_min-max02, kensho_min-max03, kensho_min-max04, kensho_min-max05, kensho_min-max06, kensho_min-max07, kensho_min-max08, kensho_min-max09, kensho_min-max10, kensho_rand01, kensho_rand02, kensho_rand03, kensho_rand04, kensho_rand05, kensho_rand06, kensho_rand07, kensho_rand08, kensho_rand09, kensho_rand10 |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
00_sample_01.txt | RE | 188 ms | 39024 KB |
00_sample_02.txt | RE | 178 ms | 38512 KB |
kensho_diff01 | RE | 177 ms | 38512 KB |
kensho_diff02 | RE | 177 ms | 38512 KB |
kensho_diff03 | RE | 180 ms | 38512 KB |
kensho_diff04 | RE | 176 ms | 38512 KB |
kensho_diff05 | RE | 175 ms | 38512 KB |
kensho_min-max01 | RE | 176 ms | 38512 KB |
kensho_min-max02 | RE | 178 ms | 38512 KB |
kensho_min-max03 | RE | 178 ms | 38512 KB |
kensho_min-max04 | RE | 176 ms | 38512 KB |
kensho_min-max05 | RE | 184 ms | 38512 KB |
kensho_min-max06 | RE | 183 ms | 38512 KB |
kensho_min-max07 | RE | 187 ms | 38512 KB |
kensho_min-max08 | RE | 180 ms | 38512 KB |
kensho_min-max09 | RE | 178 ms | 38512 KB |
kensho_min-max10 | RE | 179 ms | 38512 KB |
kensho_rand01 | RE | 177 ms | 38512 KB |
kensho_rand02 | RE | 178 ms | 38512 KB |
kensho_rand03 | RE | 182 ms | 38512 KB |
kensho_rand04 | RE | 181 ms | 38512 KB |
kensho_rand05 | RE | 180 ms | 38512 KB |
kensho_rand06 | RE | 180 ms | 38512 KB |
kensho_rand07 | RE | 181 ms | 38512 KB |
kensho_rand08 | RE | 178 ms | 38512 KB |
kensho_rand09 | RE | 177 ms | 38512 KB |
kensho_rand10 | RE | 183 ms | 38512 KB |