You are viewing a single comment's thread. Return to all comments →
I wrote the below in sql server to solve this. The output is as expected but i still get some 'run time error'. i wonder why!!
create procedure triangle as declare @i int declare @j int
set @i=1 set @j=20
while @j>=@i begin print replicate ('*', @j) set @j=@j-1 end
execute triangle
Seems like cookies are disabled on this browser, please enable them to open this website
Draw The Triangle 1
You are viewing a single comment's thread. Return to all comments →
I wrote the below in sql server to solve this. The output is as expected but i still get some 'run time error'. i wonder why!!
create procedure triangle as declare @i int declare @j int
set @i=1 set @j=20
while @j>=@i begin print replicate ('*', @j) set @j=@j-1 end
execute triangle