Skip to content

Instantly share code, notes, and snippets.

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

Zelakolase Zelakolase

🏠
Working from home
  • Ottawa
View GitHub Profile
/*
* This code proofs my own proof of collatz, on Sunday Oct.24 2021 at 2:52AM Cairo Local Time
* Since 4,2,1 is a ending hole for any positive number, it belongs to f(x) = 2 ^ x
* Since x can go to infinity, any number that lands on the series of 2 ^ x can also go infinity.
* for example, 138829902545689665 falls to 16 (which belongs to 2^x series) after 384 iterations.
*/
public class CollatzProof {
public static void main(String[] args) {
long numberStart = 92233720368547758L; // HUGE TIT- I MEAN NUMBER
@Zelakolase
Zelakolase / main.java
Created March 18, 2021 00:26
لغة غريبة
import java.util.HashMap;
public class main {
public static void main(String[] args) {
String in = "عملت كود عشان لغة غريبة بجافا";
String[] in_arr = in.split("\\s+");
String out = "";
for(int i = 0;i<in_arr.length;i++) {
String word = in_arr[i];
String letter = word.substring(0,1);
@Zelakolase
Zelakolase / main.java
Last active August 19, 2020 20:30
ZTE ZXHN H108N V2.5 UPnP Exploitation code
// Video: https://www.youtube.com/watch?v=WvzIZ-JH-7k
// UPnP should be enabled for the target side
// UPnP default port is 52869
// Credits: Morad Abdelrasheed and Zeyad Azima
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.net.HttpURLConnection;
@Zelakolase
Zelakolase / HelloWorld.java
Last active January 17, 2020 22:33
Java code to solve Quadratic Trinomials by Factorization
public class HelloWorld{
// formula: x^2+dx+c, You gonna input d and c
public static void main(String []args){
double b=1;
double c=12;
double d=-8;
for(double a=-2147483647;a<2147483647;a++) {
if(a==0) {
a++;
}
package com.gypsyengineer.tlsbunny.jsse;
import javax.net.ssl.SSLServerSocket;
import javax.net.ssl.SSLServerSocketFactory;
import javax.net.ssl.SSLSocket;
import javax.net.ssl.SSLSocketFactory;
import java.io.*;
/*
* Don't forget to set the following system properties when you run the class:
@ylixir
ylixir / main.md
Last active April 27, 2025 10:55
Blog : Getting bluetooth headphones working on void linux with ALSA

I have a great little sub $20 bluetooth headset that I've been too lazy to get working on my laptop. I run Void Linux because for me systemd creates more headaches than it solves and I prefer minimalism for a machine beholden to a battery. Similarly I consider PulseAudioto have an unacceptable level of overhead for what it brings to the table. So my goal is to get my headphones working on my laptop with these constraints.

Unfortunately the [Bluetooh page of the Void Wiki][void-wiki] is less than useless. I should probably go back and add some stuff for them one of these days. Fortunately the [Bluetooth page of the Arch Wiki][arch] is more helpful, but not 100% precise.

You will need to install Bluez with # xpbs-install -Sy bluez and add yourself to the bluetooth group with the command # useradd -G bluetooth . You might want to log out and back in at this point. This way you can make sure your

@Jack-Saleem
Jack-Saleem / Watermelon.java
Created January 15, 2016 13:05
codeforces 4A Watermelon program in java
import java.util.Scanner;
public class Watermelon
{
public static void main(String[] args)
{
int w;
Scanner input = new Scanner(System.in);
w=input.nextInt();
if(w>2)
{