Guest User

Untitled

a guest
Sep 16th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
AutoIt 0.27 KB | None | 0 0
  1.  
  2. #include <Array.au3>
  3.  
  4. Global $a[10]
  5.  
  6. For $i = 0 To 6 Step 1
  7.     $a[$i] = Random()
  8. Next
  9.  
  10. _ArrayDisplay($a)
  11. _Blubb($a)
  12. _ArrayDisplay($a)
  13.  
  14. Func _Blubb(ByRef $a)
  15.     For $i = UBound($a) - 1 To 0 Step -1
  16.         If $a[$i] Then
  17.             ReDim $a[$i+1]
  18.             Return
  19.         EndIf
  20.     Next
  21. EndFunc
Add Comment
Please, Sign In to add comment