Q17Numerical5 Marks13 Apr 2025
Let Z be a row in the "Words" table such that Z.Word = "success". What will be the value of alphaDict["s"] at the end of the execution of the following pseudocode?
```
Procedure updateDict(Z, dict)
i = 1
while(i <= Z.LetterCount){
x = ith letter of Z.Word
if(not isKey(dict, x)){
dict[x] = 1
}
else{
dict[x] = dict[x] + 1
}
i = i + 1
}
return(dict)
End updateDict
alphaDict = {"s": 1, "u": 2, "c": 1, "e": 1}
alphaDict = updateDict(Z, alphaDict)
```
Press Enter to check.