搜尋此網誌

2026年2月25日星期三

Feature of Python

Indentation in Python

Unlike many other programming languages, Python uses indentation to define code blocks instead of braces {} or keywords. This makes indentation not just stylistic, but syntactically required.

Microsoft Copilot

Operators in Python

Double asterisk in Python: exponentiation operator

print(10 % 3)   # 1   (because 10 = 3*3 + 1)

print(25 % 7)   # 4   (because 25 = 7*3 + 4)

The operator <= means “less than or equal to.”

Python has two membership operators that test whether a value is present in a sequence (like a list, tuple, string, or set) or a mapping (like a dictionary).

d = {"x": 10, "y": 20}

print("x" in d)        # True

print(10 in d)         # False (10 is a value, not a key)

Microsoft Copilot

Trans fat and cholesterol profile

Trans fats raise “bad” LDL cholesterol and often lower “good” HDL cholesterol, creating one of the worst possible cholesterol profiles for your heart and blood vessels. Even small amounts in the diet are linked to higher rates of heart attack and death from heart disease.

Head‑to‑head trials suggest trans fats disturb the cholesterol profile at least as much as, and in some ways more than, cholesterol‑raising saturated fats. Unlike most saturated fats, trans fats both increase LDL and lower HDL, which makes their overall effect on the LDL/HDL ratio particularly harmful. Because of this pattern, expert groups describe trans fats as the most damaging dietary fat per gram for cardiovascular health.

Deep Research using Perplexity.ai

拉之眼

The Eye of Ra is a powerful ancient Egyptian symbol representing the sun god Ra's protective yet destructive force. While it shares a similar "wedjat" design with the Eye of Horus, the Eye of Ra is traditionally depicted as the right eye and symbolizes solar energy, royal authority, and divine retribution.

Google AI overview

2026年2月24日星期二

Data structures of Python

Lists are ordered collections. Sets are unordered collections.

A tuple is one of the built-in data types used to store collections of items. It’s similar to a list but with a key difference: tuples are immutable, meaning once created, their elements cannot be changed, added, or removed.

immutable: that cannot be changed; that will never change

Similarities of sets and dictionaries:
  • Both can be modified after creation
  • Both are defined with curly brackets
  • Both are unordered collections
Source mainly from Microsoft Copilot

v > c

Tachyons are hypothetical subatomic particles that always travel faster than the speed of light. Proposed to exist within the framework of special relativity, they possess imaginary mass and would speed up as they lose energy, requiring infinite energy to slow down to light speed. No experimental evidence confirms their existence.

Google AI Overview

星芒效果

要拍攝出漂亮的星芒效果,核心技巧是使用小光圈(通常為 f/11-f/16)對點光源進行拍攝。將相機固定在三腳架上,結合低 ISO 和長曝光,可以使夜景、路燈或太陽的單點光線發散成清晰的放射狀線條。

Google AI overview

Large improvement of hardware

The William Lowell Putnam Mathematical Competition is the premier, notoriously challenging mathematics competition for undergraduate students in the U.S. and Canada, held annually on the first Saturday of December.

pant: to breathe quickly with short breaths, usually with your mouth open, because you have been doing some physical exercise, or because it is very hot

slush: partly melted snow that is usually dirty

toggle switch: an electrical switch that you move up and down or backwards and forwards

full-blown: having all the characteristics of somebody/something; fully developed

exploit: exploit something to use something well in order to gain as much from it as possible


Bill Gates "Source Code"

Online Dictionaries Used:

hk.dictionary.search.yahoo.com

www.oxfordlearnersdictionaries.com

2026年2月19日星期四

Something basic

Single equal sign (=) is an assignment operator.

Double equal signs (==) are used as a comparison operator.

Microsoft Copilot

2026年2月17日星期二

"宝石" 伶 feat. 幾田りら

I made up my mind not to cry

I knew it all along

There'd be a time we'd eventually part

Memories send so much loneliness

Into my heart

Should have been sick of

Our foolish exchanges long ago but

I kind of miss it now

As if you've forgotten how it ended last time

Your regular smile

Really suits you

We're just continually searching

For the one and only version of ourselves

Like a star that floats up in the sky by day

It's there, even if it can't be seen

We've had it in our possession all along

This invaluable thing

Be continuing to improve upon it, one day

We'll find it

The song I memorized repeatedly

The melody that's seeped into me

Circulates through my body

I'll burn them all into memory

That irreplaceable

Place where I'm meant to return

Hurt at times

Bringing together that have yet to heal

We talked until morning

To bodies that felt a little lighter

We poured in hope

And kept going for it, didn't we

I'll be leaving here tonight

Leaving behind this loneliness I've accumulated

Don't have to put everything into words

I can tell when I see you nod

The times we've spent together up 'til now

The light that shined upon us

No one can shut it out

It'll be okay

I started out alone

And today, I walk on my own again

But in this baggage I shoulder

Are our days spent together, like gemstones

I'm no longer alone

This light that continues to shine in my heart

Is without a doubt, you

Forever and ever

Greeting

"How are you" and "how are you doing" are common, casual greetings inquiring about someone's wellbeing, often answered with "I'm fine" or "Good, thanks". "How do you do" is a formal, old-fashioned greeting, usually used upon first introduction, and is properly answered by repeating the phrase back, rather than answering the question.

Google AI overview

Python Course Quiz

a = [1,2,3]   # 'a' points to the list [1,2,3]

b = a            # 'b' now points to the same list as 'a'

a = [4,5,6]   # 'a' is reassigned to a new list [4,5,6]

Importantly, this does not change b; b still points to the original [1,2,3]

Microsoft Copilot

2026年2月10日星期二

brainstorming

mystique: the quality of being mysterious or secret that makes somebody/something seem interesting or attractive

A corrupter (or corruptor) is a person or thing that causes moral decay, dishonesty, or the rotting/spoiling of something.

sober: not drunk (= not affected by alcohol)

chaperone: (in the past) an older woman who, on social occasions, took care of a young woman who was not married

dewdrop: a small drop of dew or other liquid

irrevocably: in a way that cannot be changed

forage (for something) (of a person) to search for something, especially using the hands

exploit something: to use something well in order to gain as much from it as possible

sift: to examine something very carefully in order to decide what is important or useful or to find something important

mocktail: a cocktail (= mixed drink) that does not contain any alcohol

glitch: a small problem or fault that stops something working successfully

tedious: ​lasting or taking too long and not interesting

doggedly: ​in a way that shows that you are determined and do not give up easily

plead: to ask somebody for something in a very strong and serious way

tollbooth: a small building by the side of a road where you pay to drive on a road, go over a bridge, etc.

inclination: a feeling that makes you want to do something

skeptically: ​in a way that shows doubts that a claim or statement is true or that something will happen


Bill Gates "Source Code"

Online Dictionaries Used:

hk.dictionary.search.yahoo.com

www.oxfordlearnersdictionaries.com

dictionary.cambridge.org

2026年2月3日星期二

Final Quiz

In C++, the term insertion operation usually refers to adding elements into data structures (like arrays, vectors, lists, sets, or maps) or inserting output into streams.

concatenate: to put things together as a connected series

#include <iostream>

#include <fstream>

#include <string>

using namespace std;


int main() {

    ifstream inputFile("example.txt"); // open file for reading


    if (!inputFile) {

        cerr << "Error opening file!" << endl;

        return 1;

    }


    string line;

    while (getline(inputFile, line)) { // read line by line

        cout << line << endl;          // print each line

    }


    inputFile.close(); // close the file

    return 0;

}


Microsoft Copilot

Poker

lottery: a way of raising money for a government, charity, etc. by selling tickets that have different numbers on them that people have chosen. Numbers are then chosen by chance and the people who have those numbers on their tickets win prizes.

slob: a person who is lazy and dirty or untidy

stake: something that you risk losing, especially money, when you try to predict the result of a race, game, etc., or when you are involved in an activity that can succeed or fail

grungy: dirty in an unpleasant way

Seven-card stud, also known as Seven-Toed Pete or Down-The-River, is a variant of stud poker.

khakis: a strong yellow-brown cloth, used especially for making military uniforms

stow: to put something in a safe place


Bill Gates "Source Code"

Online Dictionaries Used:

hk.dictionary.search.yahoo.com

www.oxfordlearnersdictionaries.com

Anubis, ancient Egyptian god

Anubis, ancient Egyptian god of funerary practices and care of the dead, represented by a jackal or the figure of a man with the head of a jackal. In the Early Dynastic period and the Old Kingdom, he enjoyed a preeminent (though not exclusive) position as lord of the dead, but he was later overshadowed by Osiris. His role is reflected in such epithets as “He Who Is upon His Mountain” (i.e., the necropolis), “Lord of the Sacred Land,” “Foremost of the Westerners,” and “He Who Is in the Place of Embalming.”

阿努比斯,古埃及掌管葬禮儀式與亡者照護的神祇,以豺狼或人身豺狼頭的形象呈現。在早王朝時期與古王國時期,他享有至高(雖非唯一)的地位,為亡者之主,但後來逐漸被歐西里斯所取代。他的角色反映在一些尊號中,如「山上之神」(即墓地)、「聖地之主」、「西方人之首」以及「在防腐之所者」。

His particular concern was with the funerary cult and the care of the dead; hence, he was reputed to be the inventor of embalming, an art he first employed on the corpse of Osiris. In his later role as the “conductor of souls,” he was sometimes identified by the Greco-Roman world with the Greek Hermes in the composite deity Hermanubis.

他特別關注葬禮崇拜與亡者的照護;因此,他被傳說為防腐術的發明者,並首先將此技藝運用於歐西里斯的屍體。在他後來作為「靈魂引導者」的角色中,希臘羅馬世界有時將他與希臘神赫密斯相結合,形成合成神赫曼努比斯。

Source: https://www.britannica.com/topic/Anubis

Anubis is the guardian of mummies and cemeteries. He is responsible for weighing the heart during the judgement after death and guiding the deceased along the path to the afterlife.

阿努比斯是木乃伊與墓地的守護者。他負責在死後審判時秤量心臟,並引導亡者走向通往來世的道路。

Yan, H. Y. (2025). Ancient Egypt Unveiled: Treasures from Egyptian Museums. The Hong Kong Palace Museum.

The human heart was balanced on the scale against Ma’at’s feather of truth. If the heart weighed more than the feather, the person’s identity would essentially cease to exist: the hybrid deity Ammit would eat the heart, and the soul would be destroyed. But if the heart weighed the same as the feather, the deceased would pass through the underworld (Duat) and into the Afterlife.

人類的心臟在天秤上與瑪亞特的真理之羽相衡。如果心臟比羽毛更重,這個人的身份便會徹底消失:混合神阿米特會吞食心臟,靈魂也將被毀滅。但若心臟與羽毛重量相同,亡者便能通過冥界(杜阿特),進入來世。

Source: https://egyptianmuseum.org/deities-Anubis

Translated with Microsoft Copilot and Edited