dimanche 8 mai 2016

String pattern printing

How to print a string like below? S St Str Stri String

have tried this dono how to proceed after this` String s="kavitha";

    for(int i=1;i<=s.length();i++)
    {

        System.out.println(s.charAt(i));
    }`

Aucun commentaire:

Enregistrer un commentaire