You are on page 1of 1

SciLabandMatLabBasicDifference

Matlab SciLabEquivalent
FromFilemenuopenandcreatenewsourcefile.Source FromFilemenuopenandcreatenewsourcefile.Source
filehasextension.m filehasextension.sci
%whenfunctionreturnsavalue //whenfunctionreturnsavalue
function[r]=test(a,b) functionr=test(a,b)
end endfunction

%whenfunctiondoesnotreturnsavalue //whenfunctiondoesnotreturnsavalue
function[]=test(a,b) functiontest(a,b)
end endfunction

%comment //comment
Writethefunctionnameincommandwindowtorun ExecuteMenuandloadintoscilabandthenWritethe
functionnameincommandwindowtorun.
mod(x,y) Pmodulo(x,y)
fprintf(1,formatstring,var1,var2,) printf(formatstring,var1,var2,)

You might also like