This preview shows page 1. Sign up to view the full content.
Unformatted text preview: 1 ) end end if (p 1 <> END(L 1 ) or p 2 <> END(L 2 )) then return(true) else return(false) end 5. Give, using A big O @ notation, the worst case running times of the following procedures as a function of n. Provide some calculation/justification. Just a formula only is not sufficient. a. procedure P1(n:integer); var i,j,k : integer; /* assume arrays are such that access error never occurs*/ begin for i:=1 to n do if ( (n is not odd) and (n is not divided by 5)) then begin...
View Full Document
- Spring '03