Skip to content · ⁨ข้ามไปยังเนื้อหา⁩

String length · ⁨ความยาว string⁩

English

String length

A C-string is a row of characters that ends with a hidden null terminator. Return how many characters come before it — basically writing strlen yourself. Walk an index forward until you reach the terminator, counting as you go.

ไทย

ความยาวสตริง

C-string คือชุดของตัวอักษรที่ลงท้ายด้วย null terminator ที่ซ่อนอยู่ คืนค่าว่ามีตัวอักษรกี่ตัวมาก่อนมัน — โดยพื้นฐานแล้วการเขียน strlen เอง เดิน index ไปข้างหน้าจนกว่าจะถึง terminator นับไปพร้อมกัน

Log in or create account · ⁨เข้าสู่ระบบหรือสร้างบัญชี⁩

IGCSE, A-Level & AP