Forums

Forums

Ask, search, or answer any question related to the CCC.

Not logged in | Login

Sort by:
Create New Post

CCC 2020 J3 - Art Solution

#Morgan Su, BayviewSS
N=int(input())
hcX=-1
hcY=-1
lX=101
lY=101
#Variables for points extrema

for i in range(N):
    coord=input()
    length=len(coord)
   ...
By msu7 on 8/25/2025
0

CCC 2019 J3 - Cold Compress Solution

#Morgan Su, BayviewSS
N=int(input())

array=[]         #Store all input lines
posCount=0       #character index tracker for current line
mul=1            #Cou...
By msu7 on 8/7/2025
0

CCC 2019 J2 - Time To Decompress Solution

#Morgan Su, BayviewSS
L=int(input())
array=[]

for i in range(L):
    array+=[input()]

for i in range(L):
    string=array[i]
   
#Check if second char is sp...
By msu7 on 8/6/2025
0

CCC 2020 J2 - Epidemiology Solution

#Morgan Su, BayviewSS
P=int(input())
N=int(input())
R=int(input())

total=N
amt=N
counter=0

#keep simulating days until total of infected exceeds P
while tot...
By msu7 on 8/4/2025
1

CCC 2020 J2 - Epidemiology Solution


By msu7 on 8/4/2025
-1

CCC 2019 J1 - Winning Score Solution

#Morgan Su, BayviewSS
#If statements, operators and variables
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
f=int(input())

m=int...
By msu7 on 7/17/2025
0

CCC 2020 J1 - Dog Treats Solution

#Morgan Su, BayviewSS
#Operations and if statements
s=int(input())
m=int(input())
l=int(input())

w=int(2*m)
a=int(3*l)

x=int(s)+int(w)+int(a)

if x>10:
 ...
By msu7 on 7/17/2025
0

CCC 2021 J2 - Silent Auction Solution

#Morgan Su, Bayview SS
#Arrays
num=int(input())
name=[]
bid=[]
for i in range(num):
    name+=[input()]
    bid+=[int(input())]

s=sorted(bid)
length=len(s)
m...
By msu7 on 7/14/2025
0

CCC 2021 J1 - Boiling Water Solution

#Morgan Su, BayviewSS
#Calculations and comparing integers
T=int(input())
P=5*T-400

if T<100:
    print(P)
    print(1)
if T==100:
    print(P)
    print(...
By msu7 on 7/14/2025
0

CCC 2018 J1 - Fergusonball Ratings Solution

#Morgan Su, BayviewSS
#Calculations and arrays
pn=int(input())
s=[]
f=[]
total=[]
for i in range(pn):
    s+=[int(input())]
    f+=[int(input())]

counter=0
t...
By msu7 on 7/14/2025
0

CCC 2022 J1 - Cupcake Party Solution

#Morgan Su, BayviewSS
#Using calculations to solve for remaining cupcakes
r=int(input())
s=int(input())

numr=r*8
nums=s*3
total=numr+nums
new=total-28

print...
By msu7 on 7/13/2025
0

CCC 2018 J2 - Occupy Parking Solution

#Morgan Su, BayviewSS
#Comparing parking spot occupation with positions of C in either string
N=int(input())
dayOne=input()
dayTwo=input()

counter=0

for i i...
By msu7 on 7/13/2025
0

CCC 2018 J1 - Telemarketer or not? Solution

#Morgan Su, BayviewSS
#Check whether input matches telemarketer criteria, and if so: print ignore

a=int(input())
b=int(input())
c=int(input())
d=int(input())...
By msu7 on 7/8/2025
0

2018 S5 - Maximum Strategic Savings

/*
CCC '18 S5 - Maximum Strategic Savings
Author: Dan Shan
Date: 2025-05-25
Observation: Only need one portal per planet and one plane per city
2d grid with p...
By Dan-Shan on 6/20/2025
1

CCC 2016 S4 - Combining Riceballs

/*

CCC '16 S4 - Combining Riceballs

Dan Shan, Oakville Trafalgar High School

Date: 2025-06-13

Recursive Dynamic Programming

Observation: order of merging doesn't effec...

By Dan-Shan on 6/14/2025
2

2017 J1 - Quadrant Selection Solution

# Advay Chandorkar, Glenforest SS (advayc)
# py3 solution for 17' j1
x = int(input())
y = int(input())

if y > 0 and x > 0:
    print('1')
elif x < 0...
By advayc on 4/13/2025
0

2017 J2 - Shifty Sum

# Advay Chandorkar, Glenforest SS (advayc)
# py3 solution for 16' j3
n=(input())
k=int(input())
sum=0
for i in range(k+1):
    sum += int(n)
    n += '0'

pri...
By advayc on 4/13/2025
0

CCC 2016 J2 - Magic Squares Solution

# Advay Chandorkar, Glenforest SS (advayc)
# py3 solution for 16' j3
square = []
sums_row = []
sums_col = []
for i in range(4):
    currentrow = [0,0,0,0]
   ...
By advayc on 4/13/2025
0

CCC 2016 J1 - Tournament Selection Solution

# Advay Chandorkar, Glenforest SS (advayc)
# py3 solution for 16' j2
games = [input()for i in range(6)]
win = games.count('W')

if win == 6 or win == 5:
    p...
By advayc on 4/13/2025
0

CCC 2016 J3 - Hidden Palindrome Solution

# Advay Chandorkar, Glenforest SS (advayc)
# py3 solution for 16' j3
t = input()
n=len(t)
c=[]
for i in range(n):
    for j in range(n):
        x=t[i:j+1]
  ...
By advayc on 4/13/2025
0

CCC 2025 S4 - Floor is Lava Solution

# Advay Chandorkar, Glenforest SS (advayc)
# py3 solution for 25' s4

import heapq

# read number of levels (N) and number of tunnels (M)
N, M = map(int, inpu...
By advayc on 3/12/2025
1

CCC '25 - Donut Shop

D=int(input())
E=int(input())


for _ in range(E):
    e=input()
    Q=int(input())


    if e=="+":
       ...
By WATER on 3/2/2025
0

CCC '23 S5 - The Filter Solution

//By Timothy Shnayder, Newmarket Highschool

//To solve this problem, we first do a rough filter, then remove the bad ones with a precise filter

#include <...
By timshnayder on 10/15/2024
0

CCC '21 S5 - Math Homework Solution

//By Timothy Shnayder, Newmarket High School

/*
The idea of this problem is to first interate through each index and build it based of 
the LCM of all t...
By timshnayder on 10/15/2024
0

Needed updates

Hey everyone! If anyone is interested in helping, here are some things that we are still hoping to implement. We will continue to update this post with any new...

By Admin on 10/1/2024
100000000

Suggestions Megathread

Please use this thread to share suggestions you would like to see be implemented by the devs for this repository.


When posting a suggestion in the comments below,...

By Admin on 10/1/2024
100000001

CCC 17 S5 C++ Solution

//By Timothy Shnayder, Newmarket High School

#include 
#define pii pair
#define vpii vector>
#define vi vector
By timshnayder on 10/1/2024
1