fxDreema

    • Register
    • Login
    • Search
    • Back to the main page
    • Categories
    • Recent
    • Tags
    • Popular
    • Search

    Random Pips

    Questions & Answers
    2
    3
    487
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • amincgi
      amincgi last edited by

      is there any way to generate random numbers ranging between 10 min to 15 max pips
      0_1602323341167_01.png

      roar 1 Reply Last reply Reply Quote 0
      • roar
        roar @amincgi last edited by

        @amincgi you need 4 functions:

        • MathSrand() to initialize random number generator
        • GetTickCount() inside MathSrand() to get new starting value each tick
        • MathRand() to actually compute the random number
        • MathMod() to "scale" the number between 0-5. (and then add 10).

        https://fxdreema.com/shared/EXqjPRhEb

        Need small help? Tag me in your post
        Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

        amincgi 1 Reply Last reply Reply Quote 0
        • amincgi
          amincgi @roar last edited by

          @roar thanks a lot 🙂

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post

          Online Users

          E
          K
          J
          J
          G

          15
          Online

          146.7k
          Users

          22.4k
          Topics

          122.6k
          Posts

          Powered by NodeBB Forums | Contributors