Bitcoin Forum
May 09, 2024, 07:34:53 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: How many operation  (Read 92 times)
Kostelooscoin (OP)
Member
**
Offline Offline

Activity: 202
Merit: 16


View Profile
February 24, 2023, 02:37:54 PM
Last edit: February 24, 2023, 05:29:07 PM by Kostelooscoin
 #1

liste = [0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15]

while x == 97:


how many operation "+" can we have to obtain 97 knowing that only 17 numbers are allowed.

start with 3 + 5 + 15 numbers
1715240093
Hero Member
*
Offline Offline

Posts: 1715240093

View Profile Personal Message (Offline)

Ignore
1715240093
Reply with quote  #2

1715240093
Report to moderator
1715240093
Hero Member
*
Offline Offline

Posts: 1715240093

View Profile Personal Message (Offline)

Ignore
1715240093
Reply with quote  #2

1715240093
Report to moderator
Even in the event that an attacker gains more than 50% of the network's computational power, only transactions sent by the attacker could be reversed or double-spent. The network would not be destroyed.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715240093
Hero Member
*
Offline Offline

Posts: 1715240093

View Profile Personal Message (Offline)

Ignore
1715240093
Reply with quote  #2

1715240093
Report to moderator
1715240093
Hero Member
*
Offline Offline

Posts: 1715240093

View Profile Personal Message (Offline)

Ignore
1715240093
Reply with quote  #2

1715240093
Report to moderator
ymgve2
Full Member
***
Offline Offline

Activity: 161
Merit: 230


View Profile
February 24, 2023, 05:51:50 PM
Merited by ABCbits (1)
 #2

Look up the "Subset Sum" problem
Kostelooscoin (OP)
Member
**
Offline Offline

Activity: 202
Merit: 16


View Profile
February 24, 2023, 06:31:17 PM
Last edit: February 24, 2023, 06:45:07 PM by Kostelooscoin
 #3

Code:
import random

x = 1

while x > 0:
    liste1 = random.choice('0123456789abcdef')
    liste2 = random.choice('0123456789abcdef')
    liste3 = random.choice('0123456789abcdef')
    liste4 = random.choice('0123456789abcdef')
    liste5 = random.choice('0123456789abcdef')
    liste6 = random.choice('0123456789abcdef')
    liste7 = random.choice('0123456789abcdef')
    liste8 = random.choice('0123456789abcdef')
    liste9 = random.choice('0123456789abcdef')
    liste10 = random.choice('0123456789abcdef')
    liste11 = random.choice('0123456789abcdef')
    liste12 = random.choice('0123456789abcdef')
    liste13 = random.choice('0123456789abcdef')
    liste14 = random.choice('0123456789abcdef')
    liste15 = random.choice('0123456789abcdef')
    liste16 = 3
    liste17 = 5
    liste = 3+5+int(liste1,16)+int(liste2,16)+int(liste3,16)+int(liste4,16)+int(liste5,16)+int(liste6,16)+int(liste7,16)+int(liste8,16)+int(liste9,16)+int(liste10,16)+int(liste11,16)+int(liste12,16)+int(liste13,16)+int(liste14,16)+int(liste15,16)
    if liste == 97:
        print(str(liste16)+str(liste17)+str(liste1)+str(liste2)+str(liste3)+str(liste4)+str(liste5)+str(liste6)+str(liste7)+str(liste8)+str(liste9)+str(liste10)+str(liste11)+str(liste12)+str(liste13)+str(liste14)+str(liste15))

all good
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!