informa |
TO JEST FORMUŁKA DO PLIKU "obltabmno" if nt==0 la=get(vedit7, 'string'); [Lt brbl]=str2num(la); if (brbl<1) | (Lt<10) Lt=10; set(vedit7 , 'string' , '10'); end; set(vedit7 , 'enable' , 'off'); end; if nt<Lt; c=get(vedit3 , 'string'); [c brbl]=str2num(c); if brbl==1 if c==l1*l2 set(vedit3, 'background' , [0 1 0]); P=P+2; else set(vedit3, 'background' , [1 0 0]); P=P-1; end; end; nt=nt+1; set(vedit4, 'string' , P); set(vedit5, 'string' , 2*nt); l1=round(rand*10); l2=round(rand*10); set(vedit1, 'string' , l1); set(vedit2, 'string' , l2); set(vedit3, 'string' , ' '); end; if nt==Lt set(vedit8, 'visible' , 'on'); set(vtext7, 'visible' , 'on'); ocena=4*P/Lt/2+1; if ocena<2; ocena=2; end; set(vedit8, 'string' , sprintf('%4.1f' , ocena)); set(vedit1, 'visible' , 'off'); set(vedit2, 'visible' , 'off'); set(vedit3, 'visible' , 'off'); set(vtext1, 'visible' , 'off'); set(vtext2, 'visible' , 'off'); set(sprawdz, 'visible' , 'off'); end |