mirror of
https://github.com/appinfosapienza/so-un-bot.git
synced 2025-05-06 16:19:38 +02:00
Adapt to new bot structure
This commit is contained in:
parent
ff7e08ada9
commit
3f84e1d831
3414 changed files with 41525 additions and 709 deletions
1
legacy/Data/Questions/ingsw/0324_5/correct.txt
Normal file
1
legacy/Data/Questions/ingsw/0324_5/correct.txt
Normal file
|
@ -0,0 +1 @@
|
|||
F(x, y, z) = if (x >= 0) then (z == pow(y, x)) else (z == 1)
|
10
legacy/Data/Questions/ingsw/0324_5/quest.txt
Normal file
10
legacy/Data/Questions/ingsw/0324_5/quest.txt
Normal file
|
@ -0,0 +1,10 @@
|
|||
Un test oracle per un programma P è una funzione booleana che ha come inputs gli inputs ed outputs di P e ritorna true se e solo se il valore di output di P (con i dati inputs) è quello atteso dalle specifiche.
|
||||
Si consideri la seguente funzione C:
|
||||
-----------
|
||||
int f(int x, int y) {
|
||||
int z, k;
|
||||
z = 1; k = 0;
|
||||
while (k < x) { z = y*z; k = k + 1; }
|
||||
return (z);
|
||||
}
|
||||
Siano x, y, gli inputs del programma (f nel nostro caso) e z l'output. Assumendo il programma corretto, quale delle seguenti funzioni booleane F(x, y, z) è un test oracle per la funzione f.
|
1
legacy/Data/Questions/ingsw/0324_5/wrong1.txt
Normal file
1
legacy/Data/Questions/ingsw/0324_5/wrong1.txt
Normal file
|
@ -0,0 +1 @@
|
|||
F(x, y, z) = if (x >= 0) then (z == pow(y, x)) else (z == 0)
|
1
legacy/Data/Questions/ingsw/0324_5/wrong2.txt
Normal file
1
legacy/Data/Questions/ingsw/0324_5/wrong2.txt
Normal file
|
@ -0,0 +1 @@
|
|||
F(x, y, z) = if (x >= 0) then (z == pow(y, x)) else (z == y)
|
Loading…
Add table
Add a link
Reference in a new issue