Skip to content · ⁨コンテンツへスキップ⁩

The last letter · ⁨最後の文字⁩

English

The last letter

word is "python". Store its last character in last, without counting the letters yourself.

A negative position counts from the end: word[-1] is the last character, word[-2] the one before it. It works whatever the length.

日本語

最後尾の文字

word は "python" です。文字を自分で数えずとも、最後 の文字を last に保存してください。

負の位置は末尾から数えます:word[-1] は最後の文字、word[-2] はその前の文字です。長さがどうであっても機能します。

Log in or create account · ⁨ログインまたはアカウント作成⁩

IGCSE, A-Level & AP