ときどきの雑記帖 RE* (新南口)
猫とコンピュータ
Zガンダム@テレ玉
「宇宙を駆ける」
まだ観ていない(録画はした)ので略。
ところでここいらで新訳を観たいところだ>Z
ファーストの続編である「Z」は、「なんであそこで終わらなかったんだ!」から始まるからこそ、「救いのない世界の物語」たる扉の意味があったと思うんだよ。
— SOW@ (@sow_LIBRA11) June 9, 2025
「当時『ガンダム』の続編が望まれていたか?」という話。
— 葛西伸哉 (@kasai_sinya) June 10, 2025
まずそもそも7~80代のテレビまんがでは「枠と路線を継承したシリーズ」は当たり前でも「設定と登場人物を継承した続編」というのは、そもそも例外的な事だったというのを忘れてはいけない。
3199
公開初日に行くつもりだったのだけど やむを得ぬ事情により以下略
公開2週目以降だと上映スケジュールが色々アレ(謎)だよなあ
3199のダゴン艦長に惚れたので僕もこれからいい仕事する度に「これがプロの仕事です」「プロの仕事を見せてやる」と口角を上げてみようと思います。
— かがやこうすけ (@ReppuTenku) February 21, 2026
あー、早く観てー
プルドポーク
という食べ物があるのを知って、どんなものだろうと調べると
プルドポーク(英: pulled pork、「むしった豚肉」)とは豚の肩肉に低温でじっくり火を通し、細かくほぐしてソースで和えた料理。
pullにそんな意味あったのか
「pull」の意味・使い方・表現・読み方 - 英辞郎 on the WEB には
- 取る、抜く、むしる
あったけど
pullの意味・使い方・読み方・覚え方 | Weblio英和辞書
には見当たらない。
Graph API / JSON
仕事でごにょごにょ。 JSONはちょっと前からだけど。
世界は圏論でできている
図書館で(順番待ちして)借りてみたけど、 さすがに2週間では読み切れんわな😓
買うかねえ(で、買ったら積みっぱなしだったりするんだ😄)
haskellforall
内容はともかく(マテ)、サイトの名前(Haskell for all)が気になった
- Beyond agentic coding | Hacker News
- Haskell for all: Beyond agentic coding
- Haskell for all: My views on NeoHaskell
Software Development Is Broken. We’re Fixing It From The Language Up.
A Brief History of Bjarne Stroustrup
グラサンかけたセンセイ
A Brief History of Bjarne Stroustrup, the Creator of C++ : r/programming
ruby
✔ これはすごい! 『メソッド定義に &nil という引数を書くことで明示的にブロックを受け付けないメソッドを定義できる』 https://t.co/12KiRRKU5V
— たかおさん@スモウルビー (@takaokouji) February 16, 2026
メモ
history of boolean data type in programming
真と偽を表す整数値というかビットパターンが… という話題を見かけたので(以前にも調べたことがあるけど) ちょいと検索
- Early Use (1950s-1960s): The first commercial use of Boolean data in a computer program was by a Bell Labs engineer in 1951. However, many early languages did not have a dedicated Boolean type, often using integers (where 0 was false, and any non-zero value was true) to represent truth values.
- ALGOL 60 (1960): The language ALGOL 60 was one of the first to provide a built-in BOOLEAN data type with explicit true and false values. This proved historically significant in popularizing the concept of a distinct logical type.
- FORTRAN IV (1962): This version introduced a LOGICAL data type and truth literals (.TRUE. and .FALSE.), following the example of ALGOL 60.
- Pascal (1970): Pascal further popularized the use of a dedicated Boolean type as a predefined enumerated type, with strong type checking that required explicit conversions between Booleans and integers.
- C (1972): The original C language did not have a built-in Boolean type. Programmers continued the practice of using integers (0 for false, 1 for true). A standard _Bool type was eventually added in the C99 standard, and a bool type in C23.
- C++ (1998): The language formally introduced the bool data type with true and false keywords, though automatic conversions from scalar and pointer values remained.
- Python: From version 2.3 onward, Python introduced a bool type as a subclass of the standard integer type, with capitalized True and False constants that behave as 1 and 0 in arithmetic contexts.
↑がえーあいの出してきた結果
Booleans were first used commercially in 1951 by a Bell Labs engineer as a part of AN/FSQ-7, the massive computer that was used by the United States Air Force.
- ASCII.jp:業界に多大な影響を与えた現存メーカー 業界トップの座に君臨したIBM (2/3)
- AN/FSQ-7 Combat Direction Central - Wikipedia
- 半自動式防空管制組織 - Wikipedia
結論はない😄
が、0が偽(false)ってのは共通(一貫)しているような気がする
Excel
数式/関数:関数で列のピボット解除(アンピボット)を行う - なんでもエクセル(Nandemo Excel) に、クロス集計表(ピボットテーブル)を元の(?)状態に戻すのを 関数だけ使って行う例が載っているのだけど
=LAMBDA(範囲,LET(
行見出し,DROP(TAKE(範囲,1),,1),
列見出し,DROP(TAKE(範囲,,1),1),
値,DROP(範囲,1,1),
組換,HSTACK(TOCOL(IF(値=値,列見出し)),TOCOL(IF(値=値,行見出し)),TOCOL(値)),
FILTER(組換,TOCOL(値)<>"")
))(A:.D)
こっちはともかく、いや、
IF(値=値,列見出し) と
IF(値=値,行見出し)
で悩んだか。
というのはさておき、最近使えるようになった便利関数 (DROP、TAKE、HSTACK、TOCOL) 抜きで同じことをする
=LET(
範囲,A:D,
抽出,FILTER(範囲,INDEX(範囲,,2)<>""),
行数,ROWS(抽出)-1,列数,COLUMNS(抽出)-1,
連番,SEQUENCE(行数*列数,,0),
行番,(INT(連番/列数)+2)*{1,0,1}+{0,1,0},
列番,(MOD(連番,列数)+2)*{0,1,1}+{1,0,0},
組換,INDEX(抽出,行番,列番),
FILTER(組換,INDEX(組換,,3)<>"")
)
で結構悩んだ。とくに
行番,(INT(連番/列数)+2)*{1,0,1}+{0,1,0}
と
列番,(MOD(連番,列数)+2)*{0,1,1}+{1,0,0}
の
*{1,0,1}+{0,1,0}
や
`*{0,1,1}+{1,0,0}``
の部分。
ということで順を追って考えてみる
元データを
| X | Y | Z | |
|---|---|---|---|
| A | 1 | 2 | 3 |
| B | 4 | 5 | 6 |
| C | 7 | 8 | 9 |
| D | 10 | 11 | 12 |
| E | 13 | 14 | 15 |
とすると 組換はこう
| A | X | 1 |
| A | Y | 2 |
| A | Z | 3 |
| B | X | 4 |
| B | Y | 5 |
| B | Z | 6 |
| C | X | 7 |
| C | Y | 8 |
| C | Z | 9 |
| D | X | 10 |
| D | Y | 11 |
| D | Z | 12 |
| E | X | 13 |
| E | Y | 14 |
| E | Z | 15 |
確かに求めたい結果になっているが、
それぞれの値はINDEXでとってきているので、
その引数はどうなっているかというと
行番
| 2 | 1 | 2 |
| 2 | 1 | 2 |
| 2 | 1 | 2 |
| 3 | 1 | 3 |
| 3 | 1 | 3 |
| 3 | 1 | 3 |
| 4 | 1 | 4 |
| 4 | 1 | 4 |
| 4 | 1 | 4 |
| 5 | 1 | 5 |
| 5 | 1 | 5 |
| 5 | 1 | 5 |
| 6 | 1 | 6 |
| 6 | 1 | 6 |
| 6 | 1 | 6 |
列版
| 1 | 2 | 2 |
| 1 | 3 | 3 |
| 1 | 4 | 4 |
| 1 | 2 | 2 |
| 1 | 3 | 3 |
| 1 | 4 | 4 |
| 1 | 2 | 2 |
| 1 | 3 | 3 |
| 1 | 4 | 4 |
| 1 | 2 | 2 |
| 1 | 3 | 3 |
| 1 | 4 | 4 |
| 1 | 2 | 2 |
| 1 | 3 | 3 |
| 1 | 4 | 4 |
わかりやすいようにペアにすると (行番,列番)
| 2,1 | 1,2 | 2,2 |
| 2,1 | 1,3 | 2,3 |
| 2,1 | 1,4 | 2,4 |
| 3,1 | 1,2 | 3,2 |
| 3,1 | 1,3 | 3,3 |
| 3,1 | 1,4 | 3,4 |
| 4,1 | 1,2 | 4,2 |
| 4,1 | 1,3 | 4,3 |
| 4,1 | 1,4 | 4,4 |
| 5,1 | 1,2 | 5,2 |
| 5,1 | 1,3 | 5,3 |
| 5,1 | 1,4 | 5,4 |
| 6,1 | 1,2 | 6,2 |
| 6,1 | 1,3 | 6,3 |
| 6,1 | 1,4 | 6,4 |
ふむ。 A~E、X~Zはそれぞれ1列目、1行目だから それを取り出すには1が必要。で、 対応する部分で0を掛けて1を足すことで そうしているわけか
ところでペアの表を作るのに
=CONCAT(J1#,",",N1#)
とやったら期待した結果にならず
=MAP(J1#,N1#,LAMBDA(x,y,CONCAT(x,",",y)))
としなければならなかった(ほかにもやり方あるかもしれない)
WG 14
今回も気になったものを一つ紹介
n3805
n3805, alx-0073r1 - named arguments after varying arguments in macros
Description
It is useful to have wrappers that perform an operation on a certain parameter of an API (often the first or last), and otherwise transparently call the wrapped API. It usually looks like this:
#define FOO(a, b, c) foo(bar(a), b, c)The preprocessor is usually good for these, because it offers a simplicity that functions can’t match. Simplicity means it is easier to review for correctness, and thus result in less bugs.
On the other hand, the preprocessor doesn’t have any type safety, and one can make accidents more easily than with functions. Those accidents usually result in silent bugs.
In the case of the FOO() macro above, assuming that the arguments b and c to the function foo() are of a similar type (e.g., both are integers), then one could accidentally type the macro as
#define FOO(a, b, c) foo(bar(a), c, b)and get a bug. Interestingly, a function wouldn’t be better:
void FOO(int a, int b, int c) { foo(bar(a), c, b); }The accident is the same in this case, and we get some unnecessary overhead of defining the function.
In the case of this macro, it can be done better as a macro by using varying arguments, which makes sure that accidents such as this one can’t happen:
#define FOO(a, ...) foo(bar(a), __VA_ARGS__)However, sometimes one wants to do the same with the last argument to an API:
#define ASD(a, b, c) asd(a, b, bar(c))
In this case, the preprocessor doesn’t have the ability to take all the preceding arguments as a block. This should be easy to implement, though. It could be easily expressed as
#define ASD(..., c) asd(__VA_ARGS__, bar(c))There’s no fundamental reason why this can’t be implemented easily in the preprocessor.
便利っちゃあ便利だけど、プリプロセッサーがますます高機能に
six thoughts on generating c
WG 14とは関係ないけど、Cつながりで
six thoughts on generating c — wingolog
- static inline functions enable data abstraction
- avoid implicit integer conversions
- wrap raw pointers and integers with intent
- fear not memcpy
- for ABI and tail calls, perform manual register allocation
- what’s not to like
新刊近刊
帰宅支援マップ首都圏版
帰宅支援マップ首都圏版 | 昭文社 地図 編集部 |本 | 通販 | Amazon
何年か前から買っているのだけど新しいのが出たので購入。
東日本大震災のときは当日に歩いて帰ったんだけど(3時間くらいだったか?)、 今の職場は家からさらに遠くなってるし 東日本大震災のあとは しばらくは会社にとどまれって方針になってると思うけどまあ。
365+1
翔泳社さんから届きました! pic.twitter.com/woS6DZb4Gb
— yonekubo / アーキテクトの教科書 (@tyonekubo) February 17, 2026
書店で早売りされてたのを見かけたけど、 製品の性格上中身確認はできなかった (シュリンクラップされていた)😓
バーナード嬢曰く。
バーナード嬢曰く。 (8) (REXコミックス) : 施川 ユウキ: 本
お、やっとか。 が、これもじわじわお高くなってますねえ…
新九郎、奔る!
スピリッツでの最新回(2/20発売号)でついに連載第1回の場面になったけど、 最後の2ページでいろいろ…😓
そういやそうだったっけか>堀越御所襲撃の結果(諸説あります)
平和の国の島崎へ
モーニング連載。
カウントダウンが0日になってどうなるかと思ったら…
いろいろ
【おすすめ本】
— ジュンク堂書店池袋本店 PC書担当 (@junkudo_ike_pc) February 1, 2026
6Fの2月おすすめ本は
『対話の技法』
納富信留 著
笠間書院 刊
「対話」自体をテーマに、その深みを哲学的な観点から考える一冊です。
#ジュンク池袋のおすすめ本 pic.twitter.com/TKoVE7FXUj
2/13先行販売:978-4-297-15436-3 技術評論社 『人を動かすハッカーの技術 ソーシャルエンジニアリングの実践と防御』 Joe Gray 著 Jin Maeda 訳 10冊入荷 pic.twitter.com/8k6z9lBKbU
— ジュンク堂書店池袋本店 PC書担当 (@junkudo_ike_pc) February 13, 2026
. @uchan_nos @Egh2Deywos @nkata245 @rkarsnk_new @totsugeki_tai @PG_MANA_
— 市川 真一 (@tenpoku1000) February 16, 2026
2026/04/10 発売予定らしいです。選挙関連の無駄ツイートが原因でミュートしてる人も多いかと思いますが:
LinuxコードリーディングとRISC-Vで学ぶ オペレーティングシステム入門 - 共立出版 https://t.co/z6Od3wYh37
本を出版することになりました!
— Issei Suzuki | 🇺🇸 プロダクトサイエンス代表 (@issei613) February 13, 2026
『amazon式言語化の技術』(2/27発売)
「アイデアはあっても、事業を形にする技術がない…」
8年前、事業会社の再建に取り組んでいた私がぶつかった壁でした。
答えを求めてMBAへ、そしてアマゾン本社へ。… pic.twitter.com/xex5lPbb4l
awk
gawk
- Is is still possible to match any arbitrary byte via MinRX engine in UTF
- Re: Is is still possible to match any arbitrary byte via MinRX engine in
「文字」単位で扱っているところに「バイト」単位のあれこれを 入れ込むのは面倒だよなあ
gnulib
strnul
bug-gnulib (date)
を眺めていたらstrnulなる見慣れないものがサブジェクトに現れた
- More uses of strnul(3)
- [PATCH v2 1/1] man/man3/strnul.3: New page
- [PATCH v2 0/1] Document strnul(3)
- [PATCH v1 1/1] man/man3/strnul.3: New page
- [PATCH v1 0/1] Document strnul(3)
- [RFC v1 1/1] lib/: Implement strnul()
- [RFC v1 0/1] strnul(): New macro
で、ちょっと追いかけてみると [RFC v1 0/1] strnul(): New macro の
I think it would be interesting to add a new strnul() macro. I’ve been using it for some time in shadow-utils, and it helps simplify quite some code here in gnulib. It’s the obvious s+strlen(s), without repeating ’s’, which is error-prone. I’ve implemented it as
#define strnul(s) strchr(s, '\0')which allows me to implement it as a trivial macro. gcc -O1 optimizes this as if it were a simple strlen(3) call.
から始まっていろいろ議論している模様
emacs
elpaってなんだろう?🤔
AI
斬新な詰め方だ…… https://t.co/AOXqRpGHPb
— Takuto Wada (@t_wada) February 18, 2026
どういう流れでそう動いたんだろう?>えーあい
たぶん50代は全員知ってます
たぶん50代は全員知ってます https://t.co/z2dHYiSy63
— サムソン高橋 (@samsontakahashi) February 16, 2026
MathenaticaとかAIとか
— 解答略 (@kaitou_ryaku) February 19, 2026
プロジェクト・ヘイル・メアリー
わし、プロジェクト•ヘイル•メアリーのタイトルってイマイチやと思うんすよね。
— 木下昌輝@豊臣家の包丁人 11月発売 (@musketeers10) February 18, 2026
というのは、ヘイル•メアリーがなんのことかわかんない。… https://t.co/qO97gJa3FH
1970年代児童SFとして『プロジェクト・ヘイル・メアリー』が翻訳されてたら、タイトルは絶対「やけくそ作戦」ですよね。なんか表紙までイメージできる。
— Munechika Nishida (@mnishi41) February 19, 2026
ついった検索したら同じこと6人くらい言ってたけどプロジェクト・ヘイル・メアリーの邦題はこれでしょ。意味合ってるし pic.twitter.com/QfY3lakIZb
— 大都会最前線 (@action_jackson3) February 19, 2026
time to xxx
「我々昭和おじさんはお前たちには想像もできないようなものを見てきた。main()一本数千行で書かれたCソース…カウンタ上位にフラグを組み込んだbitfield…if-elseが100段くらい連なるネスト…だがそんな思い出も時間と共にやがて消える。雨の中の涙のように」
— ウチューじん・ささき (@uchujin17) February 16, 2026