CSES - Datatähti 2025 alku - Results
Submission details
Task:Pizzat
Sender:Japivee
Submission time:2024-10-28 15:40:54 +0200
Language:Node.js
Status:READY
Result:0
Feedback
groupverdictscore
#10
Test results
testverdicttime
#10.10 sdetails
#20.10 sdetails
#30.10 sdetails
#40.10 sdetails
#50.11 sdetails
#60.10 sdetails
#70.10 sdetails
#80.10 sdetails
#90.10 sdetails
#100.10 sdetails
#110.10 sdetails
#120.10 sdetails
#130.11 sdetails

Code

#!usr/bin/env node

function pizza(number) {
    numberlist = number.split(" ");
    numberlist.forEach(function(number, index){
        numberlist[index] = Number(number);
    });
    console.log(Math.floor(numberlist[1]*numberlist[2]/numberlist[0]) + " " + Math.ceil(numberlist[1]*numberlist[2]/numberlist[0]));

}








local = false;
const readline = require('node:readline');
const rl = readline.createInterface({
    input: process.stdin,
    output: process.stdout,
    terminal:false
});
function with_time(timing){
    rl.on(`line`, number => {
        timing(pizza, [number]);
    });
}
function without_time(){
    rl.on(`line`, number => {
        pizza(number);
    });
}
if (local) {
    const timing = require('./timing.js');
    with_time(timing);
} else {
    without_time();
}



Test details

Test 1

Verdict:

input
3 2 4

correct output
2 3

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 2

Verdict:

input
1 1 1

correct output
1 1

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 3

Verdict:

input
1 1 2

correct output
2 2

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 4

Verdict:

input
2 1 1

correct output
0 1

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 5

Verdict:

input
2 5 7

correct output
17 18

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 6

Verdict:

input
1 1000 1000

correct output
1000000 1000000

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 7

Verdict:

input
1000 1000 1000

correct output
1000 1000

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 8

Verdict:

input
1000 1 1

correct output
0 1

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 9

Verdict:

input
997 995 997

correct output
995 995

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 10

Verdict:

input
997 994 997

correct output
994 994

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 11

Verdict:

input
997 996 995

correct output
994 995

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 12

Verdict:

input
997 996 996

correct output
995 996

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}

Test 13

Verdict:

input
997 995 499

correct output
497 498

user output
(empty)

Error:
internal/modules/cjs/loader.js:818
  throw err;
  ^

Error: Cannot find module 'node:readline'
Require stack:
- /box/input/code.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/box/input/code.js:20:18)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [ '/box/input/code.js' ]
}