FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
JavaRepository/Boris/src/laba3/CheckLastNumber.java at master · karzhouAndrew/JavaRepository · GitHub
karzhouAndrew
/
JavaRepository
Public
Notifications
You must be signed in to change notification settings
Fork
16
Star
0
Code
Issues
0
Pull requests
96
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
JavaRepository
/
Boris
/
src
/
laba3
/
CheckLastNumber.java
Copy path
More file actions
More file actions
Latest commit
History
History
History
14 lines (13 loc) · 549 Bytes
Breadcrumbs
JavaRepository
/
Boris
/
src
/
laba3
/
CheckLastNumber.java
Copy path
File metadata and controls
14 lines (13 loc) · 549 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
package
laba3
;
//To create the number. To take out "Is the last numeral '7'?".
public
class
CheckLastNumber
{
public
static
void
main
(
String
[]
args
) {
int
number
= (
int
) (
Math
.
random
() *
999
);
System
.
out
.
println
(
"Рандомное число равно "
+
number
);
if
(
number
%
10
==
7
) {
System
.
out
.
println
(
"Последняя цифра введенного числа 7"
);
}
else
{
System
.
out
.
println
(
"Последняя цифра числа не равна 7"
);
}
}
}
Back
|
FazBrowse Home
|
New Git URL