Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jweb-e002-JSP
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Pedro Rolon
jweb-e002-JSP
Commits
8d9766f3
Commit
8d9766f3
authored
Nov 29, 2018
by
Pedro Rolon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
se solucionó un error por el cual se tomaban las escaleras a la A y a la K como iguales
parent
505741f7
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
1 deletions
+4
-1
jweb-e002/build/classes/clases/Poker.class
+0
-0
jweb-e002/build/classes/servlets/SieteCartas.class
+0
-0
jweb-e002/src/clases/Poker.java
+3
-1
jweb-e002/src/servlets/SieteCartas.java
+1
-0
No files found.
jweb-e002/build/classes/clases/Poker.class
View file @
8d9766f3
No preview for this file type
jweb-e002/build/classes/servlets/SieteCartas.class
View file @
8d9766f3
No preview for this file type
jweb-e002/src/clases/Poker.java
View file @
8d9766f3
...
@@ -275,6 +275,8 @@ public class Poker {
...
@@ -275,6 +275,8 @@ public class Poker {
int
aux
=
0
;
int
aux
=
0
;
calificacion
.
add
(
6
);
calificacion
.
add
(
6
);
int
[]
ordenado
=
ordenarMano
(
mano
);
int
[]
ordenado
=
ordenarMano
(
mano
);
//Si existe 0 en la posicion 0, significa que existe una A
//porque la A está representado por un 0 al ordenar
if
(
ordenado
[
0
]==
0
){
if
(
ordenado
[
0
]==
0
){
calificacion
.
add
(
14
);
calificacion
.
add
(
14
);
aux
=
1
;
aux
=
1
;
...
@@ -286,7 +288,7 @@ public class Poker {
...
@@ -286,7 +288,7 @@ public class Poker {
else
if
(
esEscalera
(
valores
)){
else
if
(
esEscalera
(
valores
)){
int
[]
ordenado
=
ordenarMano
(
mano
);
int
[]
ordenado
=
ordenarMano
(
mano
);
calificacion
.
add
(
5
);
calificacion
.
add
(
5
);
if
(
ordenado
[
4
]==
12
&&
ordenado
[
0
]==
1
){
if
(
ordenado
[
4
]==
12
&&
ordenado
[
0
]==
0
){
calificacion
.
add
(
14
);
calificacion
.
add
(
14
);
}
}
else
{
else
{
...
...
jweb-e002/src/servlets/SieteCartas.java
View file @
8d9766f3
...
@@ -35,6 +35,7 @@ public class SieteCartas extends HttpServlet {
...
@@ -35,6 +35,7 @@ public class SieteCartas extends HttpServlet {
//Genera las cartas aleatoriamente y las almacena en un array de Cartas
//Genera las cartas aleatoriamente y las almacena en un array de Cartas
cartas
=
p
.
generarCartas
(
7
);
cartas
=
p
.
generarCartas
(
7
);
String
mejores
=
p
.
mejorJugada
(
cartas
);
String
mejores
=
p
.
mejorJugada
(
cartas
);
request
.
setAttribute
(
"cartas"
,
cartas
);
request
.
setAttribute
(
"cartas"
,
cartas
);
...
...
Write
Preview
Markdown
is supported
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