Notifications
Clear all

Learning Python

54 Posts
7 Users
49 Likes
2,847 Views
ron bentley
(@ronbentley1)
Member
Joined: 2 years ago
Posts: 385
 

@frogandtoadΒ 

I dont know why I didnt look it up!

Guido van Rossum wanted to give his programming language a name that was unique, mysterious and short, and what better than naming it PythonΒ after Monty Python's Flying Circus.

I was (am) a big Monty python fan but it was a bit arbitraryΒ  choosing to call it so.

At least I learned something new today, ha, ha.🤣

Ron B

Ron Bentley
Creativity is an input to innovation and change is the output from innovation. Braden Kelley
A computer is a machine for constructing mappings from input to output. Michael Kirby
Through great input you get great output. RZA
Gauss is great but Euler rocks!!


   
frogandtoad reacted
ReplyQuote
frogandtoad
(@frogandtoad)
Member
Joined: 5 years ago
Posts: 1458
 
Posted by: @ronbentley1

@frogandtoadΒ 

Monty?

42?

Struggling otherwise!

Ron B

PS

have you noticed that even the most innocuous of post spawn into long threads?

Indeed... Monty python was behind the naming of python... and we love it's meaning of life of 42 πŸ˜‰

Β 


   
ron bentley reacted
ReplyQuote
(@davee)
Member
Joined: 3 years ago
Posts: 1680
 

Hi @ronbentley1,

Β Β  Python was apparently chosen by Python's creator from "Monty Python's Flying Circus" ... a UK based iconic comedy program/troupe dating back to 1969, originally a short tv series, but since responsible for a few films, touring show, etc.Β  .. e.g."Naming" section in

https://en.wikipedia.org/wiki/Python_(programming_language)

'42' comes from Hitchhiker's Guide to the Galaxy by Douglas Adams ... another Brit, originally a radio play series, but since converted to a book, tv series and a (*****) film

https://en.wikipedia.org/wiki/The_Hitchhiker%27s_Guide_to_the_Galaxy

Best wishes, Dave

Β 


   
ReplyQuote
frogandtoad
(@frogandtoad)
Member
Joined: 5 years ago
Posts: 1458
 
Posted by: @ronbentley1

@frogandtoadΒ 

I dont know why I didnt look it up!

Guido van Rossum wanted to give his programming language a name that was unique, mysterious and short, and what better than naming it PythonΒ after Monty Python's Flying Circus.

I was (am) a big Monty python fan but it was a bit arbitraryΒ  choosing to call it so.

At least I learned something new today, ha, ha.🤣

Ron B

I'm a big fan of the monty πŸ˜‰


   
ron bentley reacted
ReplyQuote
ron bentley
(@ronbentley1)
Member
Joined: 2 years ago
Posts: 385
 

@davee , @frogandtoad

Yep, I am old enough to have watched both series when they first aired!

We Brits know to to write anorak comedy!🤣

Ron B

Ron Bentley
Creativity is an input to innovation and change is the output from innovation. Braden Kelley
A computer is a machine for constructing mappings from input to output. Michael Kirby
Through great input you get great output. RZA
Gauss is great but Euler rocks!!


   
frogandtoad and DaveE reacted
ReplyQuote
Inq
 Inq
(@inq)
Member
Joined: 2 years ago
Posts: 1900
Topic starter  
Posted by: @frogandtoad

spaceship 3 way comparison operator

I'll be dipped!Β  I read this... and thought, miss-print? joke? I had to Google it!Β Β 

It'd really be nice if theyΒ also made it like a ?: operator.Β  Now that I'd use!Β  Maybe in #21. Something like:

const char*   altitude <=> 0 ? "USAF auguered in!" : "Army has lead in their shoes" : "Naval Aviator with the gods";
Β 
It struck me some time ago that when someone adds the ESP8266/ESP32 functionality, that they've totally replaced the compilers (under the covers) maybe to gcc or something like it.Β  Not sure... since I don't use any Arduino hardware anymore.Β  I've found on a few occasions when I suggest something on the forum, they report back that it doesn't work for them and sure enough if I switch to an Uno and compile... it pukes.Β  It's almost like Arduino (the company) wrote their own compiler for their boards.Β Β 
Β 
Posted by: @frogandtoad

We are seriously RIPPED OFF here in AUS, taxed to the F&^%^EN eyeballs!

This is not meant to be inflammatory, it's just my ignorance asking to be enlightened.Β  I have to admit that I don't know the politics behind Australia's current state of affairs.Β  From what I gather someone down-under told China to go pound-sand and China has gotten all huffy.Β  Just wondering if you ignore the pain of the taxes, do they have a fundamental high-ground ethics reason behind them?Β  The few things I hear about Australian policies seemed more like common sense and things I'd wish our country would do.Β  BUT, what little I've read is not from a common Australian citizen.

VBR,

Inq

Β 

Β 

3 lines of code = InqPortal = Complete IoT, App, Web Server w/ GUI Admin Client, WiFi Manager, Drag & Drop File Manager, OTA, Performance Metrics, Web Socket Comms, Easy App API, All running on ESP8266...
Even usable on ESP-01S - Quickest Start Guide


   
ReplyQuote
frogandtoad
(@frogandtoad)
Member
Joined: 5 years ago
Posts: 1458
 

@ronbentley1

Posted by: @frogandtoad

@ronbentley1

Posted by: @ronbentley1

@frogandtoadΒ 

Go for it, post away, I am sure you will start a good series of debates and queries.

We are here to be enlightened!!

Only joking, but you clearly have a passion here and it would be great if you might share it to provide an opportunity for members to develop their understanding and skills.

If we are not prepared to learn, then what's the point!? We owe it to ourselves to explore and develop.

Looking for to new challenges

Regards

Ron B

Thanks Ron!

Indeed... I am passionate about programming, and I truly love to teach people, and not just about programming, that's why I am here!

I am no where near the best, but I do love to interact, debate and challenge the narrative to explore and arrive to the best outcomes for all in sundry... that's me in a nutshell πŸ˜‰

I will think of something to post, that relates to such discussion and thoughts!

Cheers

Ok, I just thought of a very basic example, based on a recent post no less, from @barrie thread: (Writing a timing function).

From my understanding, the goal was to recreate a [delay function], with the difference that it did not block all CPU execution as per the default delay function does (please do correct me if I am wrong!).

With that in mind... I will plagiarise (and slightly modify @inq working code), to show off some of the power of C++, with respect to scope and naming conflicts/symbols within the language.

namespace barry {
 Β 
 Β Β Β bool delay(u32 interval) {

 Β Β Β Β Β static u32 lastTime = millis();
 Β Β Β Β Β u32 currentTime = millis();

 Β Β Β Β Β if (currentTime - lastTime >= interval) {
 Β Β Β Β Β Β Β return lastTime = currentTime;
 Β Β Β Β Β Β }

 Β Β Β Β Β return false;
 Β Β Β Β }
 }

void setup() {
 Β Serial.begin(9600); 
 }

void loop() {
 Β Β // useage...
 Β Β if(barry::delay(1000)) {
 Β Β Β Β Serial.println("executing...");
 Β Β Β }
 }

...namespaces are cool, when you want to use the same library name ('delay') for your own library without conflict!

FYI: namespaces have been around since C++11

Cheers

Β 


   
ron bentley reacted
ReplyQuote
frogandtoad
(@frogandtoad)
Member
Joined: 5 years ago
Posts: 1458
 

@inqΒ 

Posted by: @frogandtoad
Posted by: @frogandtoad

spaceship 3 way comparison operator

I'll be dipped!Β  I read this... and thought, miss-print? joke? I had to Google it!Β Β 

It'd really be nice if theyΒ also made it like a ?: operator.Β  Now that I'd use!Β  Maybe in #21. Something like:

const char*   altitude <=> 0 ? "USAF auguered in!" : "Army has lead in their shoes" : "Naval Aviator with the gods";
Β 

It's no joke πŸ™‚ - The C++ language has vastly improved over the years - the C++23 ISO standard is not far away, and will offer even greater functionality!

Posted by: @inq

It struck me some time ago that when someone adds the ESP8266/ESP32 functionality, that they've totally replaced the compilers (under the covers) maybe to gcc or something like it.Β  Not sure... since I don't use any Arduino hardware anymore.Β  I've found on a few occasions when I suggest something on the forum, they report back that it doesn't work for them and sure enough if I switch to an Uno and compile... it pukes.Β  It's almost like Arduino (the company) wrote their own compiler for their boards.Β 

True that!

We are in 2022, and as far as I'm concerned... Arduino UNO* is dead!
ESP8266 / ESP32 are IMHO, the current defaults in terms of power and language compatibility.

If you need something *significantly* faster, then look into Teensy πŸ˜‰

Posted by:Β @frogandtoad

We are seriously RIPPED OFF here in AUS, taxed to the F&^%^EN eyeballs!

This is not meant to be inflammatory, it's just my ignorance asking to be enlightened.Β  I have to admit that I don't know the politics behind Australia's current state of affairs.Β  From what I gather someone down-under told China to go pound-sand and China has gotten all huffy.Β  Just wondering if you ignore the pain of the taxes, do they have a fundamental high-ground ethics reason behind them?Β  The few things I hear about Australian policies seemed more like common sense and things I'd wish our country would do.Β  BUT, what little I've read isΒ notΒ from a common Australian citizen.

VBR,

Inq

The truth is that your country, mine and a few others are controlled by the same ar^#%(*)es (WEF, UN, WHO), and we need to eradicate them before they eradicate us!

I will never let these bastards rule the people if I can help it, and I will do my best to stop them!Β  Some people are not awake, but I really hope they wake up quickly, before it's too late for all of us!

Keep fighting these bastards!

Cheers


   
ReplyQuote
robotBuilder
(@robotbuilder)
Member
Joined: 5 years ago
Posts: 2042
 

@frogandtoadΒ 

We are seriously RIPPED OFF here in AUS, taxed to the F&^%^EN eyeballs!

Nothing I can do about it so I just don't think about it.

I can't comment any further without getting political and would be off topic for these forums.

Β 


   
ReplyQuote
Page 4 / 4