• Forums
  • View New Posts
  • View Today's Posts
  • Search
  • Members
  • Calendar
  • Help
  • Extras
Forum stats
Show team
View New Posts
View Today's Posts
Lowlands Tactical: Forum
Login to account Create an account
Login
Username/Email:
Password: Lost Password?
 

  Lowlands Tactical: Forum Publiek Speeltuin
1 2 Next »
De grote programmeer opdracht 2016!

Thread Modes
De grote programmeer opdracht 2016!
Sacha Offline
Administrator
*******
Posts: 1,305
Threads: 266
Joined: Aug 2014
Reputation: 7
#2
08-10-2016, 03:15 PM (This post was last modified: 08-10-2016, 03:16 PM by Sacha.)
Code:
#!/usr/bin/env python3
import random
myArray = []
for n in range(0,10):
 myArray.append(random.randint(1,100))
urArray = myArray.copy()
myArray[-1] = -7
print("1st Array: "+str(myArray)+"\n"+"2nd Array: "+str(urArray))

Result Wrote:$ ./test.py
1st Array: [32, 67, 97, 67, 5, 23, 53, 33, 4, -7]
2nd Array: [32, 67, 97, 67, 5, 23, 53, 33, 4, 63]
Website Find
Reply
Share Thread:            


Messages In This Thread
De grote programmeer opdracht 2016! - Sacha - 08-10-2016, 03:13 PM
RE: De grote programmeer opdracht 2016! - Sacha - 08-10-2016, 03:15 PM
RE: De grote programmeer opdracht 2016! - PingWing - 08-10-2016, 03:44 PM
RE: De grote programmeer opdracht 2016! - Archu - 08-10-2016, 04:00 PM
RE: De grote programmeer opdracht 2016! - Sacha - 08-10-2016, 07:31 PM
RE: De grote programmeer opdracht 2016! - Sacha - 08-11-2016, 11:09 AM

  • View a Printable Version
  • Subscribe to this thread


Users browsing this thread:
1 Guest(s)

  • Contact Us
  • Forum team
  • Forum stats
  • Return to Top
 
  • RSS Syndication
  • Lite mode
  • Lowlands Tactical
  • Help
 
Forum software by © MyBB - Theme © iAndrew 2014



Linear Mode
Threaded Mode