Quantcast
Channel: CodeChef Discuss - latest questions
Viewing all articles
Browse latest Browse all 39796

Life, the Universe, and Everything :java Wrong Answer coming

$
0
0

Please check what is the mistake in this . I am getting wrong answer for this.

Thanks

class LifeUniverse{

public static void main(String[] args){

    String input="";
    for(int i=0; i<args.length;i++){

       input=args[i];
        if(input=="42")
            return;
        System.out.println(input);

    }

}}

Viewing all articles
Browse latest Browse all 39796

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>