Skip to content

Instantly share code, notes, and snippets.

View jukbot's full-sized avatar
🏠
Working from home

Juk - a search builder jukbot

🏠
Working from home
  • CalCal
  • Bangkok, Thailand
  • X @jukbot
View GitHub Profile
@jukbot
jukbot / RandomColorBG.css
Last active August 29, 2015 14:12 — forked from anonymous/my.css
Windows 8 random background color animate with CSS3 Animation
background: linear-gradient(131deg, #1b9475, #1b7e94, #1b4894, #281b94, #531b94, #891b94, #941b1f, #94411b, #948c1b, #51941b, #1b9430);
background-size: 2200% 2200%;
-webkit-animation: AnimationName 60s ease infinite;
-moz-animation: AnimationName 60s ease infinite;
-o-animation: AnimationName 60s ease infinite;
animation: AnimationName 60s ease infinite;
@-webkit-keyframes AnimationName {
    0%{background-position:2% 0%}
    50%{background-position:99% 100%}
    100%{background-position:2% 0%}
@jukbot
jukbot / JukFullDate.java
Last active August 29, 2015 14:13
Java Fulldate format for GUI
import java.util.Calendar;
import java.util.GregorianCalendar;
class JukFullDate {
public static void main (String args[]) {
int timeRun = 0;
//initComponents();
new Thread() {
public void run() {
@jukbot
jukbot / GetLoopTime.java
Created January 22, 2015 08:47
Display time with interval 1 second loop
import java.util.Date; //import Date class
class GetLoopTime {
public static void main (String [] args) {
while (true) { // Run infinity print
try {
Date now = new Date();
String ab;
switch (Integer.parseInt(String.format("%te",now))%10) { // Find case of some days that ended with 1, 2, or 3
case 1 : ab = "st";
break;
@jukbot
jukbot / KiloToMile.java
Last active August 29, 2015 14:13
Convert kilimeter into mile unit
import java.io.*;
import java.util.*;
public class KiloToMile {
public static void main(String[] args) {
System.out.println("Miles Kilometers");
System.out.println("----------------------------------------------");
int kilo = 0;
while(kilo < 100) {
kilo++;
float result = kilo*1.609344f;
@jukbot
jukbot / Arraylab.java
Created January 25, 2015 07:47
Cut array indexs and insert array
package arraylab;
public class Arraylab {
public static void main(String[] args) {
int arr[] = new int[100];
// add 2^i to the array where 0 <= i <= 20
// EX: arr[1,2,4,8,16,32,64,... 2^30]
int expo=1;
for (int i=0; i < 100; i++) {
arr[i] = expo;
import java.util.Stack;
public class ReverseStack {
public static void main(String[] args) {
Stack<Integer> stack = new Stack<Integer>();
stack.push(5);
stack.push(4);
stack.push(3);
stack.push(2);
doctype html
html
head
title
| Shopper2
= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true
= javascript_include_tag 'application', 'data-turbolinks-track' => true
= csrf_meta_tags
body
{
"bootstrapped": true,
"in_process_packages":
[
],
"installed_packages":
[
"AdvancedNewFile",
"All Autocomplete",
"AngularJS",
import java.util.Date;
class JukSimpleDate {
public static void main (String args[]) {
java.util.Date date = new java.util.Date();
int n = 100000000;
while(true) {
System.out.println(date.toString());
}
}
}
public class JukIsNull {
private String name;
public void setName (String name) {
if(name == null ) {
String name2 = "JukHappy";
}
this.name = (name == null) ? name : name2; // <<-- check that is null?
}
}