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
class Compilation { | |
void simpleLoop() { | |
int i; | |
for (i = 0; i < 100; i++) { | |
; // Loop body is empty | |
} | |
} | |
int align2grain(int i, int grain) { |
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
-- basic -- | |
select * from cd.facilities; | |
select name, membercost from cd.facilities; | |
select * from cd.facilities where membercost > 0; | |
select facid, name, membercost, monthlymaintenance from cd.facilities where membercost < monthlymaintenance * 1/50.0; |
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
from os import walk,path | |
import pypandoc | |
import sys | |
from collections import namedtuple | |
import queue | |
def filter_rst_meta(lines): | |
head = [] | |
rest = [] | |
for line in lines: |
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 java.util.Arrays; | |
import java.util.List; | |
import java.util.stream.IntStream; | |
import java.util.stream.Collectors; | |
public class UnicodePlay{ | |
static void fmt(String fmt, Object... rest) { | |
System.out.format(fmt, rest); | |
} |
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
package com.kamilachyla.bggen; | |
import java.awt.*; | |
import java.util.Arrays; | |
import java.util.function.BiFunction; | |
import java.util.function.UnaryOperator; | |
import java.util.stream.Stream; | |
public class Main { | |
record HSL(float hue, float saturation, float lightness){ |
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 java.lang.ProcessHandle; | |
import java.util.Arrays; | |
import java.time.Instant; | |
import java.util.concurrent.atomic.AtomicInteger; | |
public class NativeProc { | |
public static void main(String[] args) { | |
final AtomicInteger counter = new AtomicInteger(0); | |
ProcessHandle.allProcesses().peek(e->counter.incrementAndGet()).forEach(NativeProc::showInfo); | |
System.out.printf("There are %s processes%n", counter.get()); |
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
package com.kamilachyla; | |
import java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.time.Duration; | |
import java.time.LocalDate; | |
import java.time.format.DateTimeFormatter; | |
import java.util.List; | |
import java.util.StringJoiner; |
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 requests | |
from bs4 import BeautifulSoup as bs | |
import time | |
url_base = "http://staropolska.pl/slownik/" | |
url_letter = url_base + "?litera=" | |
letters = "ABCĆDEFGHIJKLŁMNOPRSŚTUVWZŹŻ" | |
def parse(html): | |
node = bs(html, 'html.parser') |
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
(ns seesaw-creds.core | |
(:use [seesaw.core]) | |
(:require [seesaw.forms :as f]) | |
(:require [seesaw.border :as b]) | |
(:require [seesaw.bind :as bi]) | |
(:require [seesaw.mig :as m]) | |
(:require [seesaw.color :as c]) | |
(:gen-class)) | |
(defn generate[ev atm tf] |
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 sys | |
from sys import * | |
import os | |
from http.server import * | |
class LogLineHandler (BaseHTTPRequestHandler): | |
def do_GET(s): | |
print("Handling get request .") | |
NewerOlder