|
I think the technical term for that number is "an Idaho".
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
I thought the localized term was "an Ireland"
Wrong is evil and must be defeated. - Jeff Ello
Never stop dreaming - Freddie Kruger
|
|
|
|
|
Some empirical testing gives 0.5V and 0.2mA, using a copper and zink nail into a generic potato (Bintje).
But not at the same time, so maximizing power gives 0.25v * 0.1mA = 0.025mW
So approx. 48 billion spuds would do it.
The potato production of Idaho 2019 was 130,900,000 CWT. The generic potato I used for the test weighed 100g so the yearly potato production of Idaho could be assumed to be in the vicinity of 65 billion spuds.
You Sir is todays winner of making a qualified guess!
Wrong is evil and must be defeated. - Jeff Ello
Never stop dreaming - Freddie Kruger
|
|
|
|
|
A potato is a large collection of chips.
|
|
|
|
|
(That's "fries" for our American cousins.)
("Chips" could work, but in the UK they would be "crisps" instead.)
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
The startup phase of the Pi uses much more than 100mA - I guess that's why it did not work.
|
|
|
|
|
Potato array.
Can you get any greener than this?
|
|
|
|
|
Has left us. I have enjoyed quite many of his books.
"If we don't change direction, we'll end up where we're going"
|
|
|
|
|
He has to have been the greatest writer of spy novels, ever. Have also enjoyed many of his books, (and film/TV adaptations), including The Constant Gardener - which demonstrated he wasn't just a "Smiley writer".
|
|
|
|
|
Yeah,
I need to decode Punycode in a project. So I find myself reading the RFC[^]. Oh look, there is a sample encoder/decoder right there in the RFC! It's my lucky day.
But wait... LibIDN[^] has a verbatim copy of this code with almost no changes with the GNU license slapped onto it.
But wait... the RFC is also 'Copyright (C) The Internet Society (2003). All Rights Reserved.' at the bottom which isn't mentioned anywhere on the GNU provided code.
I can infer that I am not the first person to ask about this... the GNU header says the following:
/*
* This file is derived from RFC 3492bis written by Adam M. Costello,
* downloaded from http://www.nicemice.net/idn/punycode-spec.gz on
* 2015-03-02 with SHA1 a966a8017f6be579d74a50a226accc7607c40133, a
* copy of which is stored in the GNU Libidn version controlled
* repository under doc/specification/punycode-spec.gz.
This is legal speak for 'We took this from a work in the public domain'.
This is like following a spider web... let's keep following the threads. So let's check the original licence at http://www.nicemice.net/idn/punycode-spec.gz[^]
B. Disclaimer and license
Regarding this entire document or any portion of it (including
the pseudocode and C code), the author makes no guarantees and
is not responsible for any damage resulting from its use. The
author grants irrevocable permission to anyone to use, modify,
and distribute it in any way that does not diminish the rights
of anyone else to use, modify, and distribute it, provided that
redistributed derivative works do not contain misleading author or
version information. Derivative works need not be licensed under
similar terms.
So without being a lawyer I interpret this as a guy named Adam wrote the Punycode RFC and put it into the public domain. Then the 'The Internet Society' slapped a copyright on the code. Then someone working on LibIDN copied the code and slapped a third license on it.
|
|
|
|
|
The GPL turned me off of anything GNU.
I use the MIT license for 99% of my stuff.
And that's trashy what they're doing. I'm glad nobody can take my public domain work (like my GLR parsing code) off CP and slap a copyright on it. If they tried someone could just find my work at CP. It sounds like Adam's work should be accessible. Can't you derive from that, and tell all of these copyright/license trolls to take a hike? That's what I would do.
Real programmers use butterflies
|
|
|
|
|
I used GPL-3 so that anyone who wants to keep their code private will have to ask for another license. My assumption is that they want to use my code for commercial purposes, in which case I want to be compensated.
If anyone knows of a better way to achieve this, I'm open to suggestions.
|
|
|
|
|
That's one way to do it.
I figure a copyright is enough for me, but I do not write my code samples with the notion that I will ever be compensated for them. If I did maybe I'd follow your lead.
I also am paranoid about putting my actual contact info out there.
Instead I have my brand (honey the codewitch) and I write articles and code under that name (for paid and free, it's my business as well)
Real programmers use butterflies
|
|
|
|
|
I don't think anyone would want the code in my articles, since they're usually simplified fragments or outright sketches. But since my GitHub license is GPL-3, I just use that for the articles.
Our residential address is also unpublished.
|
|
|
|
|
O/T: You were the one I was talking to earlier about an automatically generated assignment constructor in C++, right?
This may not be the cleanest way to do it but it's hassle free, and almost as short as an autoimplemented memberwise-copy version would be:
MyStruct(const MyStruct& rhs) { memcpy(this,&rhs,sizeof(MyStruct)); }
Real programmers use butterflies
|
|
|
|
|
memcpy ?! You'll be going to bed hungry tonight! But that's basically what
Struct(const Struct& that) = default;
does, though it's more paternalistic. If Struct owns no resources and its constructor has no side effects, go for it and revel in your naughtiness.
One thing to note is that a C++ copy constructor only invokes a base class constructor, not copy constructor, unless explicitly implemented to do otherwise.
I've now reached 🍷🍷🍷🍷, so you'd best find a proper authority lest I've led you astray!
|
|
|
|
|
I would only use it for structs whose types I could hypothetically place in a union - that is, trivial things.
Wait. are you saying
Struct(const Struct& that) = default;
Will compile? I misunderstood you earlier, if so. I thought you were saying that as a wish list item.
When was it added to the spec? There's so much to C++ if you stop using it for a few years you can miss out on features.
Real programmers use butterflies
|
|
|
|
|
Indeed! C++11, I believe. I don't use anything after that.
|
|
|
|
|
OMG you're right. I think I remember encountering it once and making a mental note of it, and then forgetting the mental note.
I love C++. I'm always learning new stuff. thanks.
Real programmers use butterflies
|
|
|
|
|
Greg Utas wrote: I don't use anything after that. Me either, although I was just porting some code last week to use std::filesystem[^] and that is extremely useful addition.
|
|
|
|
|
Ugh, you two. Years of .NET and here I am, rusty at C++ and C++ with all these new features to boot.
I'm glad I'm back in the fold, though clearly I have some catching up to do.
Real programmers use butterflies
|
|
|
|
|
You can now default any special member function:
- constructor
- destructor
- copy constructor
- move constructor
- copy operator
- move operator
EDIT: And so the Big 3 (destructor, copy constructor, copy operator)--the guideline being that if you have one, you probably need the others--became the Big 5. Not to be confused with the Big 5 in Cantonese...
modified 13-Dec-20 19:40pm.
|
|
|
|
|
honey the codewitch wrote: It sounds like Adam's work should be accessible. Can't you derive from that, and tell all of these copyright/license trolls to take a hike? That's what I would do. No, that license is worse than the GPL licence. I have enough experience in this area that I think I know what's going on here...
I suspect that Adam modified his project at a later date and added his license. Even though I am not a lawyer... I submitted over a dozen open source projects through the MSFT 'Source Code Compliance Team' and got them approved for inclusion in Windows 10. So I got to read all of those legal determinations.
There is no way LibIDN would have used that source code if the original work contained those particular paragraphs. Adam had to have added it at a later date.
I am just going to avoid it.
|
|
|
|
|
Bummer!
Real programmers use butterflies
|
|
|
|
|
You should take a look at the CP License, it's basically the same purpose as the MIT, but it adds a bit of protection for you.
Chris went through the whole license quagmire a few years ago and decided to create his own license[^] (with the help of a lawyer IIRC) to fit the whole purpose of Codeproject.
Chris's comparison for most open licenses is over here: Licenses[^]
With links to the actual license texts.
Wrong is evil and must be defeated. - Jeff Ello
Never stop dreaming - Freddie Kruger
|
|
|
|