professor gave us a stupid dumb shell exercise that i wasnt doing because its stupid . then after one hour of time , he shares the solution on the projector because many students (4th year astrophysics students) couldn’t do it . shocked , without looking at his solution i type my own in around 70 seconds
#!/bin/sh echo 'input your guess: 0 for head, 1 for tails.' read guess random_number="$(cat -v /dev/urandom | sed 'q' | wc -w)" if [ $((${random_number} % 2)) = $guess ]; then echo 'good guess!' else echo 'wrong :/' fii guess at least my classmates arent gpt-brained ? at least for coding ? yay ????