orthemagniv
New member
עזרה ב Pascal
מה הבעיה הקוד הזה? Program First; Var Length, Width, Height, Surface, Volume: real; Begin Readln (Length); write('Write the Length'); Readln (Width); write('Write the Width'); Readln (Height); write('Write the Height'); Volume:=Length*Width*Height; Surface:= 2*(Length*Width +Length*Height +Width*Height); Writeln (Volume, 'The Volume:'); Writeln (Surface, 'The Surface:'); End. תעתיקו את זה לכתבן ותיישרו לשמאל. אחרי שכותבים את ה Width זה יוצא מהתוכנית, וכשנכנסים אליה שוב זה כותב ב Height מספר משונה. למה? תודה רבה מראש!
מה הבעיה הקוד הזה? Program First; Var Length, Width, Height, Surface, Volume: real; Begin Readln (Length); write('Write the Length'); Readln (Width); write('Write the Width'); Readln (Height); write('Write the Height'); Volume:=Length*Width*Height; Surface:= 2*(Length*Width +Length*Height +Width*Height); Writeln (Volume, 'The Volume:'); Writeln (Surface, 'The Surface:'); End. תעתיקו את זה לכתבן ותיישרו לשמאל. אחרי שכותבים את ה Width זה יוצא מהתוכנית, וכשנכנסים אליה שוב זה כותב ב Height מספר משונה. למה? תודה רבה מראש!