MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/badcode/comments/qm457p/someones_homework_at_my_uni/
r/badcode • u/piratedisc • Nov 03 '21
5 comments sorted by
15
I think it isn't written in Python
2 u/CoderCharmander Nov 14 '21 More like a horrifying mix of JS and Python
2
More like a horrifying mix of JS and Python
4
No manches... smh
3
Question u/piratedisc, would a student get minus points for not using english variable names?
Image Transcription: Code
def calcularPuntaje2(sumaDeDados) if (sumaDeDados == 7 || sumaDeDados == 11); return 3 else if (sumaDeDados == 2 || sumaDeDados == 3 || sumaDeDados == 12); return -2 else : return 1 def imprimirPuntajesFinales(puntajeUno, puntajeDos) { console.log(`Puntaje Final del Jugador 1: ${puntajeUno}`); console.log(`Puntaje Final del Jugador 2: ${puntajeDos}`); if (puntajeUno > puntajeDos) console.log("El ganador es Jugador 1"); else if (puntajeUno < puntajeDos) console.log("El ganador es Jugador 2"); let data = readline("./dados.txt", {encoding: "utf-8", flag: "r"}); data.split("\n").forEach((linea) => { puntajeJ1 += obtenerPuntosJ1(linea); puntajeJ2 += obtenerPuntosJ2(linea); }); imprimirPuntajesFinales(puntajeJ1, puntajeJ2);
I'm a human volunteer content transcriber for Reddit and you could be too! If you'd like more information on what we do and why we do it, click here!
15
u/Masynchin Nov 03 '21
I think it isn't written in Python
4
u/default_user_null Nov 03 '21
No manches... smh
3
u/kostaslamprou Nov 04 '21
Question u/piratedisc, would a student get minus points for not using english variable names?
2
u/MurdoMaclachlan public boolean isInt(int i) { return true; } Nov 04 '21
Image Transcription: Code
I'm a human volunteer content transcriber for Reddit and you could be too! If you'd like more information on what we do and why we do it, click here!