Skip to content

Commit

Permalink
Merge pull request #846 from RafaelOrge92/loqueosdelaganaMK1
Browse files Browse the repository at this point in the history
Loqueosdelagana mk1
  • Loading branch information
kant003 authored Oct 24, 2024
2 parents a835da6 + feb7463 commit d456f2f
Show file tree
Hide file tree
Showing 3 changed files with 122 additions and 1 deletion.
61 changes: 61 additions & 0 deletions Rafael Gil Orge 1DAM C5.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
<!DOCTYPE html>
<html>

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>

<body>

<!DOCTYPE html>
<html>

<head>
<meta charset="UTF-8">
<title>Ejercicio 2A</title>
</head>

<body>
<p>Preceding Text</p>
<ol type="I">
<li>List Item 1
<ol type="a">
<li>Nested Item 1.1</li>
<li>Nested Item 1.2</li>
</ol>
</li>
<li>List Item 2
<ol>
<li>Nested Item 2.1</li>
<li>Nested Item 2.2
<ul>
<li type="circle">Nested Item 2.2.1</li>
<li type="circle">Nested Item 2.2.2
<ul>
<li>Nested Item 2.2.2.1</li>
<li>Nested Item 2.2.2.2</li>
</ul>
</li>
<li type="circle">Nested Item 2.2.3</li>
</ul>
</li>
<li>Nested Item 2.3</li>
</ol>
</li>
<li>List Item 3
<ul>
<li type="disc">Nested Item 3.1</li>
<li type="disc">Nested Item 3.1</li>
<li type="disc">Nested Item 3.1</li>
</ul>
</li>
</ol>
</body>

</html>

</body>

</html>
60 changes: 60 additions & 0 deletions Rafael Gil Orge 1DAM CarAccel.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
package Javacosas;

public class cocheAccel {

class coche {

// atributo
private int velocidad;

// contructor
coche() {
velocidad = 0;

}
/*
* Añade a la clase coche los siguientes métodos: int getVelocidad(). Este
* método devuelve la velocidad actual. uoid acelera(int mas). Este método
* actualiza la velocidad a mas kilómetros más. void frenafint menos). Este
* método actualiza la velocidad a menos kilómetros menos.
*/

/* getter & setter */

public int getVelocidad() {
return velocidad;
}

public void setVelocidad(int velocidad) {
this.velocidad = velocidad;
}

public void acelera(int mas) {
if (velocidad + mas > 120)
velocidad = 120;

else
// velocidad= velocidad + chop;
velocidad += mas;

}

public void frena(int cant) {
if (velocidad - cant < 0) {
velocidad = 0;
}

else {
velocidad -= cant;

}


}
}
}





2 changes: 1 addition & 1 deletion Rafael Gil Orge 1DAM Persona.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package Javacosas;
// package Javacosas;

public class Persona {
// atributos
Expand Down

0 comments on commit d456f2f

Please sign in to comment.