Commit 054b5615 authored by Sander Kvenild's avatar Sander Kvenild
Browse files

Reversed logic to improve readability

parent 43775e1a
......@@ -54,10 +54,9 @@ function print(string) {
function tre_kontoer_input() {
output.innerText = "";
// TODO: blir dette for kryptisk?
let kari = !checkboxes[0].checked ? new konto(24681632, "Kari Hansen", saldos[0].value): new barnekonto(24681632, "Kari Hansen");
let lise = !checkboxes[1].checked ? new konto(12345678, "Lise Jensen", saldos[1].value): new barnekonto(12345678, "Lise Jensen");
let petter = !checkboxes[2].checked ? new konto(16777216, "Petter Olsen", saldos[2].value): new barnekonto(16777216, "Petter Olsen");
let kari = checkboxes[0].checked ? new barnekonto(24681632, "Kari Hansen") : new konto(24681632, "Kari Hansen", saldos[0].value);
let lise = checkboxes[1].checked ? new barnekonto(12345678, "Lise Jensen") : new konto(12345678, "Lise Jensen", saldos[1].value);
let petter = checkboxes[2].checked ? new barnekonto(16777216, "Petter Olsen") : new konto(16777216, "Petter Olsen", saldos[2].value);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment