Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Randomize in tables
#1
Hello!
I am wondering whether there is an opportunity for choosing random names with some conditions. I read about diffierent random functions from random package, but they choose only one number randomly. I also thought about function, but did not come up with idea how to write it properly.
I have a table with many columns (~15) and I need to choose some random names (no exact number) which total sum is less than or equal 500. Hence, here I need to get two names AQ2 and COR and then I will extract other information from the table.

name sum city
AQ2 400 N
L3K 50 L
COR 100 Q
… … …

Could you, please, advise me how to perform it?

Thank you in advance!
Sincerely,
Anastasia
Reply


Messages In This Thread
Randomize in tables - by mariavol - Aug-15-2022, 07:46 AM
RE: Randomize in tables - by Pedroski55 - Aug-15-2022, 10:29 AM
RE: Randomize in tables - by mariavol - Aug-15-2022, 02:36 PM
RE: Randomize in tables - by deanhystad - Aug-15-2022, 09:23 PM
RE: Randomize in tables - by Pedroski55 - Aug-15-2022, 11:30 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020