FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
Java-Hackerrank-Solutions/Java/Data Structures/Stack.java at main · Manush54/Java-Hackerrank-Solutions · GitHub
Manush54
/
Java-Hackerrank-Solutions
Public
Notifications
You must be signed in to change notification settings
Fork
9
Star
21
Code
Issues
0
Pull requests
1
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
Java-Hackerrank-Solutions
/
Java
/
Data Structures
/
Stack.java
Copy path
More file actions
More file actions
Latest commit
History
History
History
16 lines (14 loc) · 383 Bytes
Breadcrumbs
Java-Hackerrank-Solutions
/
Java
/
Data Structures
/
Stack.java
Copy path
File metadata and controls
16 lines (14 loc) · 383 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
15
16
import
java
.
util
.*;
class
Stack
{
public
static
void
main
(
String
[]
argh
)
{
Scanner
sc
=
new
Scanner
(
System
.
in
);
while
(
sc
.
hasNext
()) {
String
input
=
sc
.
next
();
//Complete the code
while
(
input
.
length
() != (
input
=
input
.
replaceAll
(
"
\\
(
\\
)|
\\
[
\\
]|
\\
{
\\
}"
,
""
)).
length
());
System
.
out
.
println
(
input
.
isEmpty
());
}
sc
.
close
();
}
}
Back
|
FazBrowse Home
|
New Git URL