Rexx-justify

提供:Dev Guides
2020年6月23日 (火) 01:03時点におけるMaintenance script (トーク | 投稿記録)による版 (Imported from text file)
(差分) ← 古い版 | 最新版 (差分) | 新しい版 → (差分)
移動先:案内検索

Rexx-正当化

このメソッドは、長さの値に基づいて文字列の値を調整またはトリミングするために使用されます。

構文

justify(string,length)

パラメーター

  • String -正当化を行う必要がある文字列値。
  • 長さ-正当化の値。

戻り値

両端揃えの文字列値を返します。

/*Main program*/
options arexx_bifs
say justify('This is a tutorial',14)

上記のプログラムを実行すると、次の結果が得られます。

出力

This is a tuto