Sometimes it's easier to check:
//+------------------------------------------------------------------+ //| Script 1.mq5 | //| Copyright © 2021, Vladimir Karputov | //+------------------------------------------------------------------+ #property copyright "Copyright © 2021, Vladimir Karputov" #property version "1.000" //+------------------------------------------------------------------+ //| Script program start function | //+------------------------------------------------------------------+ void OnStart() { int x=1,y=2,z=3; Print("START: x(",(string)x,"), y(",(string)y,"), z(",(string)z,")"); x = y = z; Print("END: x(",(string)x,"), y(",(string)y,"), z(",(string)z,")"); //--- } //+------------------------------------------------------------------+
Result:
START: x(1), y(2), z(3) END: x(3), y(3), z(3)
Files:
Script_1.mq5
2 kb
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
what happens if I do this,
x = y = z