Guest User

Untitled

a guest
May 25th, 2018
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.04 KB | None | 0 0
  1. Count = 10
  2. For i = 1 to Count
  3. var[i] = Math.GetRandomNumer(100)
  4. TextWindow.Write(var[i] + โ€˜,โ€™)
  5. Endfor
  6.  
  7. Count = 10
  8. For i = 1 to Count
  9. IsFound = False
  10. While (!IsFound)
  11. TempRnd = Math.GetRandomNumer(100)
  12. For indx = 0 to var.Length
  13. If TempRnd == var[indx] Then
  14. TempRnd = Math.GetRandomNumer(100)
  15. indx = 0
  16. EndIf
  17. EndFor
  18. IsFound = True
  19. EndWhile
  20. TextWindow.Write(var[i] + ',')
  21. EndFor
  22.  
  23. Count = 10
  24.  
  25. For i = 1 to Count+1
  26. If (duplicate) Then
  27. i = i - 1
  28. duplicate = "False"
  29. EndIf
  30.  
  31. var[i] = Math.GetRandomNumber(10)
  32.  
  33. For u = 1 To i-1
  34. If var[i] = var[u] Then
  35. duplicate = "True"
  36. EndIf
  37. EndFor
  38. Endfor
  39.  
  40.  
  41. For y = 1 To Count
  42. TextWindow.Write(var[y] + ", ")
  43. EndFor
  44.  
  45. numberList[0] = 0
  46. For i = 1 To 100
  47. choice = 0
  48. While Text.IsSubText(numberList, "=" + choice + ";")
  49. choice = Math.GetRandomNumber(100)
  50. EndWhile
  51. numberList[i] = choice
  52. EndFor
  53.  
  54. For i = 1 To 100
  55. TextWindow.Write(numberList[i] + " ")
  56. EndFor
Add Comment
Please, Sign In to add comment