怎么能“1” !=" 1" [英] How can "1" != "1"

查看:70
本文介绍了怎么能“1” !=" 1"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在努力跟上你们的年轻人,所以我正在开始Java课程。作为家庭作业的一部分,我们提示用户提供1到1之间的数字。 3.我们在本章中也使用了while循环,所以我决定将提示放在while循环中以强制用户输入1,2或3.当它不起作用时我很惊讶,所以我写了一个5 -liner向您显示问题:

I''m trying to keep up with you youngsters, so I''m taking a beginning Java course. As part of a homework assignment, we were to prompt the user for a number between 1 & 3. We also used while loops in the chapter, so I decided to put the prompt in a while loop to force the user to enter 1, 2 or 3. I was very surprised when it did not work, so I have written a 5-liner to show you the problem:

展开 | 选择 | Wrap | 行号

推荐答案

这是一个秘密:


当你说

Here''s a secret:

When you say

展开 | 选择 | < span class =codeLinkonclick =WordWrap(this);> Wrap | 行号


那太疯狂了!但是,知道非常重要。有趣的是
That''s insane! But, very vital to know. It''s interesting that
展开 | 选择 | Wrap | < span class =codeLinkonclick =LineNumbers(this);>行号



那是疯了!但是,知道非常重要。有趣的是
That''s insane! But, very vital to know. It''s interesting that
展开 | 选择 | Wrap | < span class =codeLinkonclick =LineNumbers(this);>行号


这篇关于怎么能“1” !=&quot; 1&quot;的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆