Skip to content

Instantly share code, notes, and snippets.

View draganczukp's full-sized avatar

Przemek Dragańczuk draganczukp

View GitHub Profile
#include "main.h"
// Gościu nie umie nawet zapamiętać jak nazywa klasy
class Wektor{
private:
int x, y, z;
public:
Wektor(int x, int y, int z): x(x), y(y), z(z){}
Wektor(int x): x(x), y(0), z(0){}
@draganczukp
draganczukp / example
Last active June 30, 2018 16:25
An example showing the syntax of my language
namespace Example; // Optional namespace, without it everything in this file would be global
import <stdlib> // Importing namespace
import <math.Random> // Importing specific class from namespace
class Example{ // Everything must be inside of a class, like in Java
int n; // Variables that don't recieve a value immediately when declared *MUST* have a type
arr = foo(10); // Automatic variable type
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
###################################
# IMPORTANT: Copy from old config #
###################################
# Path to your oh-my-zsh installation.
export ZSH="~/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
package lab2;
import java.util.Scanner;
public class Cw6 {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
System.out.println("Podaj kwotę (max: 300 000");
int kwota = scanner.nextInt();
package lab2;
import java.util.ArrayList;
import java.util.Scanner;
public class Cw4 {
public static void main(String[] args){
Scanner in = new Scanner(System.in);
#/bin/bash
# Get the first device listed by kdeconnect-cli
DEVICE=$(kdeconnect-cli --id-only -a | sed '1q')
# Which qdbus service
SERVICE="org.kde.kdeconnect"
# Path depends on device
QPATH="/modules/kdeconnect/devices/$DEVICE/share"
import java.util.*;
public class dfs {
static class Node{
int id;
static int lastid = 0;
{
this.id = lastid++;
}
import java.util.*;
import java.util.function.BiFunction;
public class Graphs {
static class Node{
public double g = 0;
public double f = 0;
public double h = 0;
const tf = require("@tensorflow/tfjs");
require('@tensorflow/tfjs-node');
const model = tf.sequential();
const inputs = [
[0,0],
[0,1],
[1,0],
import java.text.DecimalFormat;
import java.util.Random;
public class Perceptron {
public static void main (String[] args) {
double[][] inputs = {
{1, 1},
{1, 0},
{0, 1},
{0, 0}