Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
IPDSnelting
mjtest-tests
Commits
ed45a073
Commit
ed45a073
authored
Dec 16, 2021
by
uxrog
Browse files
Merge branch 'fix/backstab' into 'master'
Remove broken Ackerman.inf.java test See merge request
!50
parents
24c54c37
d943e311
Pipeline
#182544
failed with stage
in 20 minutes and 17 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
exec/Ackermann.inf.java
deleted
100644 → 0
View file @
24c54c37
class
Ackermann
{
public
int
ack
(
int
m
,
int
n
)
{
if
(
m
==
0
)
{
return
n
+
1
;
}
else
if
((
m
>
0
)
&&
(
n
==
0
))
{
return
ack
(
m
-
1
,
1
);
}
else
if
((
m
>
0
)
&&
(
n
>
0
))
{
return
ack
(
m
-
1
,
ack
(
m
,
n
-
1
));
}
else
{
System
.
out
.
println
(
m
);
return
n
+
1
;
}
}
public
static
void
main
(
String
[]
args
)
{
Ackermann
a
=
new
Ackermann
();
System
.
out
.
println
(
a
.
ack
(
2
,
1
));
System
.
out
.
println
(
a
.
ack
(
2
,
2
));
System
.
out
.
println
(
a
.
ack
(
3
,
3
));
System
.
out
.
println
(
a
.
ack
(
3
,
8
));
System
.
out
.
println
(
a
.
ack
(
4
,
4
));
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment