Wednesday, November 1, 2017

Hershey's 巧克力像嘔吐物??

今天吃了一顆 Hershey's 巧克力糖果,一開始覺得沒怎樣,但吃完後就覺得嘴巴裡還殘留某種微酸的味道。我就去查詢 Hershey's 和 sour aftertaste。

原來 Hershey's 巧克力一直都有帶有微酸像是嘔吐物的評價。

有人猜Hershey's 用的的製造過會產生微量的丁酸(butyric acid)。根據維基百科,丁酸存在於腐臭的黃油、帕馬森乾酪、嘔吐物和腋臭中,雖然對身體沒有什麼危害,但味道是非常的噁心,而且我們的嗅覺和味覺對丁酸很敏感。

https://www.reddit.com/r/explainlikeimfive/comments/3nhoiw/eli5_why_does_american_chocolate_taste_so_bad_in/
Back when I was in Florida in 2012, I couldn't believe how bad the chocolate tasted. And I always thought it may have been in my head.
But recently I've seen a few people saying the exact same thing and I'm wondering why it tastes so bad in comparison to the chocolate we get in Europe?
It's as if it tastes like vomit..

I'm not sure 'vomit's the right word - when I first tasted American chocolate I had to spit it out, I thought it was like eating soap.

https://www.mumsnet.com/Talk/food_and_recipes/1131316-Why-does-Hershey-chocolate-taste-so-vile
When i went to Chicago a few years ago we went to the Hershey store. The store was fab the choc not so.
Dp came home with a bar today , gift from work. The kids all had some and enjoyed it but again for me it had a horrid after taste.

The stuff should not be called chocolate. Hersheys is an abomination (or however you spell it).

Hershey's 'Chocolate' Kisses have an after taste of vomit.

http://www.hexjam.com/uk/food-drink/why-does-hershey-s-chocolate-taste-so-bloody-horrible

 What was a surprise, however, was the discovery that America's favourite chocolate bar tastes rather like one imagines dog treats coated in vomit to taste.

https://www.reddit.com/r/AskReddit/comments/3mbpfv/why_does_hersheys_chocolate_taste_slightly_like/
"Why does Hersheys Chocolate taste slightly like sick?"

Saturday, May 27, 2017

Python 3.6 有哪些新特性?

剛看完了 Brett Cannon 在Pycon演講的錄影 https://youtu.be/c2rEbbGLPQc,題目是What's new in Python 3.6
Python 3.6 是由史以來增加了最多新功能的Python版本,除了Python 3.0 以外。內容飽含:

字串插值語法

>>> name = "Fred"
>>> f"He said his name is {name}."
'He said his name is Fred.'
>>> width = 10
>>> precision = 4
>>> value = decimal.Decimal("12.34567")
>>> f"result: {value:{width}.{precision}}"  # nested fields
'result:      12.35'

數字可以有下底線

>>> 1_000_000_000_000_000
1000000000000000
>>> 0x_FF_FF_FF_FF
4294967295

各種async擴充

Python 3.5增加了async/await的語法,3.6多增加了幾個該有的功能。

一個『類似檔案路徑』的物件

Python 3.4新增了一個pathlib包裝,目的是提供一個檔案系統路徑的物件Path,這樣各式各樣的檔案系統可以有專屬於它門的Path物件,然後程式碼可以更OO化。時間和日期有專用的物件,為什麼檔案系統的路徑不能有?pathlib.Path當初的優點是他跟Python內建的bytes str劃清界線。可是問題來了,很多已有的程式碼就是把路徑當作字串,包含Python自己提供的os.path模組!所以3.6裡面新增了一個os.PathLike物件,提供__fspath__的方法。這方法會迴轉字串路徑。現在pathlib.Path都繼承了os.PathLike,Python內建的各個模組也都被更新成可以接受有繼承os.PathLike的物件。


除了以上所列出的變化以外,3.6版還有很多很多的改良和新功能,請參考 https://docs.python.org/3/whatsnew/3.6.html