robocontest / ideas

2 stars 1 forks source link

Tizimda katta xatolik bor #36

Closed mbicl closed 2 months ago

mbicl commented 1 year ago

Tizimda jo'natilayotgan kod orqali fayl hosil qilish imkoniyatini to'liq o'chirish kerak, bunga faqatgina shunga ehtiyoj seziladigan masalalardagina ruxsat berish kerak. Menimcha robocontestda hali bunaqa masala yo'q.

Fayl hosil qilish orqali ko'pchilik cheaterlar yes/no chiqariladigan masalalarni yoki shunga o'xshash javobi variantlari kam masalalarni yechishmoqda. Yuborilgan kod ishlayotgan vaqtida nechanchi testga javob berayotganini bilish mumkin bo'lib qolyapti. 100-150 talab urinish orqali har bir test uchun qanday javob chiqishini aniqlab chiqishmoqda.

image image image image



image image image image



Yuqoridagi foydalanuvchilar tomonidan yuborilgan kodlar:

from pathlib import *

p=Path('ALisher')

if not(p.is_file()):

  f=open('ALisher','w')

  f.write('0')

  f.close()

f=open('ALisher')

s=f.readline()

f.close()

if s=='':

    s=1

else:

    s=int(s)+1
if s==1 or s==7 or s==9 or s==11 or s==19 or s==21 or s==23 or s==24 or s==27 or s==31 :
    print('YES')
elif s==33 or s==43 or s==45 or s==47 or s==49 or s==51 or s==53 or s==57 or s==59:
    print('YES')
elif s==38 or s==40 or s==46 or s==52 or s==60:
    print('NO')
elif s==2 or s==4 or s==12 or s==16 or s==20 or s== 22 or s==30 or s==34 or s==36:
    print('NO')
elif s==61 or s==63 or s==65 or s==67 or s==69 or s==71:
    print('YES')
elif s%2==1:
    print('NO')
else:
    print('YES')

f=open('ALisher','w')

f.write(str(s))

f.close()
from pathlib import *
from os import remove
p=Path('Sarvar')
if not(p.is_file()):
  f=open('Sarvar','w')
  f.write('0')
  f.close()
f=open('Sarvar')
s=f.readline()
f.close()
if s=='':
    s=1
else:
    s=int(s)+1
arr=[1,6,7,8,9,10,11,14,18,19,23,21,24,27,26,28,31,32,33,42,43,44,45,47,48,49,50,51,53,54,56]
if s in arr:
  print('YES')
else:print("NO")
f=open('Sarvar','w')
f.write(str(s))
f.close()
rshohruh commented 1 year ago

Ushbu turdagi misollar uchun codeforcesdafi kabi testcase li testlar tuzing.

Adizbek commented 2 months ago

Fayllar bilan ishlar cheklandi