Mwnci zfill() Function

Syntax

zfill(string)

Description

The zfill() function adds zeros (0) at the beginning of the string, until it reaches the specified length.

If the value of the len parameter is less than the length of the string, no filling is done.

Example

include("string")
a = "hello"
b = "this is more than 10 characters long"
c = "10.000"

println(zfill(a,10))
println(zfill(b,10))
println(zfill(c,10))