Bitcoin Forum
April 25, 2024, 03:54:45 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 [2]  All
  Print  
Author Topic: Retrieve lost satoshis  (Read 3405 times)
virtualx
Hero Member
*****
Offline Offline

Activity: 672
Merit: 507


LOTEO


View Profile
November 21, 2015, 02:34:20 AM
 #21

Quote
...
Quote
Quote
I like to get them back and learn from everything in the journey to reach that goal.
I already learnt some python and want to see how far I can get on my own.
I prefer to use C++.
Why? Is it more efficient?

It is a compiled language vs an interpreted one.  Compiled languages are almost always much more efficient than interpreted ones.

From a coding perspective, coding one may be much more efficient than the other depending on your skill set.  e.g. If you don't know Prolog or C++, but do know Python very well, it might be quicker to code and run everything in Python than to spend time learning one of them, then coding and running.

Ah, I already had a suspicion that it was due to compiling.
Makes sense.

I actually started programming a year ago, with arduino in C.
However, for this project I already found a lot written in python which I could use so I figured I could better go this way.
Perhaps I should try and find the same bits and pieces and redo the code in C.
I think I have more than enough homework for now to be able to continue  Smiley
Thanks for all the help.


If I'm not incorrect, the python interpreter is written in C, so yah, you're just adding a layer of abstraction when you use python.  However, for one-off scripts like this one, it's probably not worth it to worry about all the typing and memory management of C, just get yer script going so you can  have some fun.  Let us know how you're proceeding.  I, for one, appreciate your attitude.  I like doing things myself simply for the educational experience.
good

The official Python interpreter is indeed written in C, you can find the source code on python.org. There are Python to C++ compilers but I have not tried them. I recommend using what works best for your project.

...loteo...
DIGITAL ERA LOTTERY


r

▄▄███████████▄▄
▄███████████████████▄
▄███████████████████████▄
▄██████████████████████████▄
▄██  ███████▌ ▐██████████████▄
▐██▌ ▐█▀  ▀█    ▐█▀   ▀██▀  ▀██▌
▐██  █▌ █▌ ██  ██▌ ██▌ █▌ █▌ ██▌
▐█▌ ▐█ ▐█ ▐█▌ ▐██  ▄▄▄██ ▐█ ▐██▌
▐█  ██▄  ▄██    █▄    ██▄  ▄███▌
▀████████████████████████████▀
▀██████████████████████████▀
▀███████████████████████▀
▀███████████████████▀
▀▀███████████▀▀
r

RPLAY NOWR
BE A MOON VISITOR!
[/center]
1714017285
Hero Member
*
Offline Offline

Posts: 1714017285

View Profile Personal Message (Offline)

Ignore
1714017285
Reply with quote  #2

1714017285
Report to moderator
1714017285
Hero Member
*
Offline Offline

Posts: 1714017285

View Profile Personal Message (Offline)

Ignore
1714017285
Reply with quote  #2

1714017285
Report to moderator
The network tries to produce one block per 10 minutes. It does this by automatically adjusting how difficult it is to produce blocks.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714017285
Hero Member
*
Offline Offline

Posts: 1714017285

View Profile Personal Message (Offline)

Ignore
1714017285
Reply with quote  #2

1714017285
Report to moderator
1714017285
Hero Member
*
Offline Offline

Posts: 1714017285

View Profile Personal Message (Offline)

Ignore
1714017285
Reply with quote  #2

1714017285
Report to moderator
1714017285
Hero Member
*
Offline Offline

Posts: 1714017285

View Profile Personal Message (Offline)

Ignore
1714017285
Reply with quote  #2

1714017285
Report to moderator
tspacepilot
Legendary
*
Offline Offline

Activity: 1456
Merit: 1076


I may write code in exchange for bitcoins.


View Profile
November 21, 2015, 08:30:12 PM
 #22

Quote
...
Quote
Quote
I like to get them back and learn from everything in the journey to reach that goal.
I already learnt some python and want to see how far I can get on my own.
I prefer to use C++.
Why? Is it more efficient?

It is a compiled language vs an interpreted one.  Compiled languages are almost always much more efficient than interpreted ones.

From a coding perspective, coding one may be much more efficient than the other depending on your skill set.  e.g. If you don't know Prolog or C++, but do know Python very well, it might be quicker to code and run everything in Python than to spend time learning one of them, then coding and running.

Ah, I already had a suspicion that it was due to compiling.
Makes sense.

I actually started programming a year ago, with arduino in C.
However, for this project I already found a lot written in python which I could use so I figured I could better go this way.
Perhaps I should try and find the same bits and pieces and redo the code in C.
I think I have more than enough homework for now to be able to continue  Smiley
Thanks for all the help.


If I'm not incorrect, the python interpreter is written in C, so yah, you're just adding a layer of abstraction when you use python.  However, for one-off scripts like this one, it's probably not worth it to worry about all the typing and memory management of C, just get yer script going so you can  have some fun.  Let us know how you're proceeding.  I, for one, appreciate your attitude.  I like doing things myself simply for the educational experience.
good

The official Python interpreter is indeed written in C, you can find the source code on python.org. There are Python to C++ compilers but I have not tried them. I recommend using what works best for your project.

Right, but C++ is just C with classes.  You should be able to compile your C code with g++.  Anyway, I think this topic has drifted a bit from the original intention of this thread.  Let's leave off about interpreters here.  If suiyan wants to start another thread about intepreters, we can wait for that.
findftp (OP)
Legendary
*
Offline Offline

Activity: 1022
Merit: 1006

Delusional crypto obsessionist


View Profile
July 01, 2016, 02:50:24 PM
 #23

I got my satoshis back!  Grin
I just picked up this thing again and see where I could end up with noob python skills and new insights.
Estimated time to check all possibilities was 270 days but I found my key already within 20 hours!
I thought to let it run, and resume the script after optimizations to speed things up. I was not going to wait 270 days, but I was (extremely) lucky I guess.
My script does approximately 15 keys/second (4 instances, 60 k/s total) and checks against a cleaned up version of https://bitcointalk.org/index.php?topic=267618.msg15398605#msg15398605

The address generation goes by 100 keys/second, but to check that address against the UTxO goes even slower, 15 keys/second.
There were 750 million addresses to check...

It's very slow, but I'm still happy with the result.
Although the reward was only 1 mBTC, I learned a lot during the process.  Smiley


Now let's see if I can optimize this a few factors...
tspacepilot
Legendary
*
Offline Offline

Activity: 1456
Merit: 1076


I may write code in exchange for bitcoins.


View Profile
July 05, 2016, 02:38:23 AM
 #24

I got my satoshis back!  Grin
I just picked up this thing again and see where I could end up with noob python skills and new insights.
Estimated time to check all possibilities was 270 days but I found my key already within 20 hours!
I thought to let it run, and resume the script after optimizations to speed things up. I was not going to wait 270 days, but I was (extremely) lucky I guess.
My script does approximately 15 keys/second (4 instances, 60 k/s total) and checks against a cleaned up version of https://bitcointalk.org/index.php?topic=267618.msg15398605#msg15398605

The address generation goes by 100 keys/second, but to check that address against the UTxO goes even slower, 15 keys/second.
There were 750 million addresses to check...

It's very slow, but I'm still happy with the result.
Although the reward was only 1 mBTC, I learned a lot during the process.  Smiley


Now let's see if I can optimize this a few factors...


Lol, only 20 hours of cpu time but nearly 9 months of forum time.  Anyway, congratulations!  I also learned a lot by playing around with key and address generation.  Cheers!
findftp (OP)
Legendary
*
Offline Offline

Activity: 1022
Merit: 1006

Delusional crypto obsessionist


View Profile
July 05, 2016, 09:38:53 PM
 #25

I got my satoshis back!  Grin
I just picked up this thing again and see where I could end up with noob python skills and new insights.
Estimated time to check all possibilities was 270 days but I found my key already within 20 hours!
I thought to let it run, and resume the script after optimizations to speed things up. I was not going to wait 270 days, but I was (extremely) lucky I guess.
My script does approximately 15 keys/second (4 instances, 60 k/s total) and checks against a cleaned up version of https://bitcointalk.org/index.php?topic=267618.msg15398605#msg15398605

The address generation goes by 100 keys/second, but to check that address against the UTxO goes even slower, 15 keys/second.
There were 750 million addresses to check...

It's very slow, but I'm still happy with the result.
Although the reward was only 1 mBTC, I learned a lot during the process.  Smiley


Now let's see if I can optimize this a few factors...


Lol, only 20 hours of cpu time but nearly 9 months of forum time.  Anyway, congratulations!  I also learned a lot by playing around with key and address generation.  Cheers!

Meanwhile, I optimized my script (with this) so it does about 8000 keys/second  Smiley Still not extreme but now it only takes two days to scan all possibilities.
I also found another address with balance which had a similar pattern that I used! About 7mBTC Grin
But, the UTxO set I used is from may this year. When I checked the address at current block height I saw that the coins were already spent. The coins were on that address for few weeks.

Anyway, it's a nice way to learn python and memory management! Wink




Pages: « 1 [2]  All
  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!