Announcement

Collapse
No announcement yet.

Middle Character for a command line parameter

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Middle Character for a command line parameter

    PHP Code:
    public class test {

        public static 
    void main (String [] input_data){

            
    String dato =  input_data[0];

            
    System.out.print( (dato).charAt( (dato.length()) /2  )  );

            
    //Alternative version
            //System.out.print( (input_data[0]).charAt( (input_data[0].length()) /2  )  );


        
    }

    | VFX Artist, C++ Programmer, HW Overclocker | Web: xgiovio.com Email: xgiovio@gmail.com Twitter: @xgiovio
Working...
X

Google Profile


My name is Giovanni Di Grezia, but people call me xgiovio.

Here is my homepage:.

I'm a VFX Artist and Software Developer.

Giovanni Di Grezia