Skip to content

Commit

Permalink
Solve Internship in python
Browse files Browse the repository at this point in the history
  • Loading branch information
deniscostadsc committed Sep 24, 2024
1 parent 9e6e8f5 commit a5ee586
Show file tree
Hide file tree
Showing 7 changed files with 22,150 additions and 0 deletions.
13 changes: 13 additions & 0 deletions solutions/beecrowd/2533/2533.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import sys

for n in sys.stdin:
n = int(n)
sum_n_c = 0
sum_c = 0

for _ in range(n):
n, c = map(int, input().split())
sum_n_c += n * c
sum_c += c

print(f'{sum_n_c/(sum_c * 100):.4f}')
16 changes: 16 additions & 0 deletions solutions/beecrowd/2533/generate_in.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/usr/bin/env bash

set -euo pipefail

TESTCASES=1000
MAX_M=40
MAX_N=100
MAX_C=90

for _ in $(seq "${TESTCASES}"); do
m=$((RANDOM % MAX_M + 1))
echo "${m}"
for _ in $(seq "${m}"); do
echo "$((RANDOM % (MAX_N + 1))) $((RANDOM % MAX_C + 30))"
done
done
Binary file added solutions/beecrowd/2533/imgs/estagio_fig.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit a5ee586

Please sign in to comment.