Just i try to create an time relativation calculator, based on the relativation theorie of 'Albert Einstein'...
So this is my script, written in PB5.6.2, Windows XP:
Code: Select all
;TIME RELATIVATION CALCULATOR - RB5.6.2 - WINDOWS XP
;Global Variables [@Numbers]
Global Speed.f = 0.0
Global Second.f = 1.000
Global Lightspeed.i = 299792458 / Second
Global Time.f = Time - Second / Speed
;Global Variables [@Strings]
Global AskSpeed.s = ""
Global ResultLightspeed.s = ""
Global ResultTime.s = ""
;Open Console
If OpenConsole()
;Print Information to the new line per/rule
PrintN("Official Lightspeed: 299792458 Meter / Second ")
PrintN("Official Seconds / Second: 1.000")
PrintN("")
PrintN("Typ 'Stop' to Close Console")
PrintN("")
;From Numerical to String
AskSpeed = StrF(Speed)
ResultLightspeed = Str(Lightspeed)
ResultTime = StrF(Time)
;Ask Forever while you typ 'Stop'
While (AskSpeed = "Stop")
;Typ the speed your rize to the universe
Print("How fast will you want rize to the universe?: ")
AskSpeed = Input()
;Calculate Numbers and Print to Console
PrintN("Personal Lightspeed: " + ResultLightspeed)
PrintN("Personal Seconds / Second: " + ResultTime)
;End loop
Wend
EndIfBut there is an other problem too...
- The calculations are not realistic... just they calculations results are not all right the same as how it must be
hearth about the result... just please, figure out whats wrong with the calculations and then correct my code
to make the calculations all right same as be hearth...
Thanks for our help, Jamie.



