Q40.The following pseudocode is executed using the "Library" dataset. What will `count` represent at the end of the execution?
```
A = 0, count = 0
while(Table 1 has more rows){
Read the first row X in Table 1
if(X.Year > A){
A = X.Year
}
Move X to Table 2
}
while(Table 2 has more rows){
Read the first row Y in Table 2
if(Y.Year != A){
count = count + 1
}
Move Y to Table 1
}
```
Save
Check
Details
Q40
10 Jul 2022
Q40.The following pseudocode is executed using the "Library" dataset. What will `count` represent at the end of the execution?
```
A = 0, count = 0
while(Table 1 has more rows){
Read the first row X in Table 1
if(X.Year > A){
A = X.Year
}
Move X to Table 2
}
while(Table 2 has more rows){
Read the first row Y in Table 2
if(Y.Year != A){
count = count + 1
}
Move Y to Table 1
}
```