clc //to calculate speed c=3*10^8 //light speed (m/s) m=2.25 //mass m of a body be 2.25 times its rest mass mo i.e. m=2.25m0 //formula is v=c sqrt(1-(m0/m)^2) v=c*sqrt(1-(1/m)^2) disp(" speed is v="+string(v)+"m/s")