This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.os.Bundle | |
import androidx.appcompat.app.AppCompatActivity | |
const val t = "TEST" | |
class MainActivity : AppCompatActivity() { | |
override fun onCreate(savedInstanceState: Bundle?) { | |
super.onCreate(savedInstanceState) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0x1204f318a6b87d530ca2f6646ac0f489d2dcfce9 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Copyright (c) 2014 kademika.com | |
*/ | |
import java.awt.Color; | |
import java.awt.Dimension; | |
import java.awt.Graphics; | |
import java.util.Random; | |
import javax.swing.JFrame; | |
import javax.swing.JPanel; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class BattleFieldTemplate extends JPanel { | |
boolean COLORDED_MODE = true; | |
int desk_step = 64; | |
int tank_move_step = 7; | |
long tank_speed = 500; | |
int tankX = 0; | |
int tankY = 0; | |
void runTheGame() throws Exception { | |
moveRandom(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Main { | |
public static void main(String[] args) { | |
printNumbers(1,133); | |
} | |
static void printNumbers(int i, int n) { | |
while(i < n){ | |
n++; | |
i =n +1; | |
System.out.println("n: "+n + "\ni: "+i); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static void start(int number) { | |
if (number <= 0) { | |
System.out.println("Start falied"); | |
return; | |
} | |
for (int i = number; i >= 0; i--) { | |
System.out.println(i); | |
} | |
System.out.println("Go!"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void runTheGame() throws Exception { | |
move(2); | |
move(2); | |
move(2); | |
move(1); | |
move(4); | |
move(4); | |
move(3); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void runTheGame() throws Exception { | |
int direction = 1; | |
while (true) { | |
if (direction == 1) { | |
if ((tankX + tank_move_step) >= (BF_WIDTH - desk_step)) { | |
tankX = 512; | |
direction = 0; | |
} else { | |
tankX += tank_move_step; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Temp { | |
public static void main(String[] args) { | |
int i = 1; | |
while (i <= 10) { | |
System.out.println(i); | |
if (i <= 10) { | |
i++; | |
continue; | |
} | |
break; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Temp { | |
public static void main(String[] args) { | |
int i=1; | |
while (true){ | |
System.out.println(i); | |
i++; | |
if (i > 10){ | |
break; | |
} | |
} |
NewerOlder