Skip to content

Instantly share code, notes, and snippets.

View 0x73hahd's full-sized avatar
Inactive for some time due to unfortunate reasons

Shahd Mostafa Riyad 0x73hahd

Inactive for some time due to unfortunate reasons
View GitHub Profile
@AmruthPillai
AmruthPillai / rsa.c
Created August 8, 2017 05:14
RSA Algorithm in C
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int checkPrime(int n) {
int i;
int m = n / 2;
for (i = 2; i <= m; i++) {
if (n % i == 0) {
@palopezv
palopezv / dwm_config_pulseaudio.h
Last active March 30, 2025 12:16 — forked from neuro-sys/dwmconfig.h
dwm volume control with hardware multimedia keys (pipewire, pulseaudio, amixer and light as an extra)
/**
* dwmconfig.h
* Hardware multimedia keys
*/
/* Somewhere at the beginning of config.h include: */
/*
You obviously need the X11 development packages installed, X11proto in particular, but
here is the location of the keysyms header upstream copy if you can't bother
using the contents of your own hard drive. ;-P
@icella
icella / CurrentTimeId.java
Last active September 2, 2024 18:01
Java – Ways to Generate Unique Ids in Java
/**
* The object creation time can be set to object’s identifier property.
* For this purpose, System.currentTimeMillis() can be used. However,
* two or more objects may be created in a single millisecond.
* In this case, these objects will have the same id which is unacceptable.
* One way to cope with this problem is to use System.nanoTime().
* Even if the nano time is the smallest interval we can use, it does not
* also guarantee the uniqueness. To provide unique time stamps,
* I got help from AtomicReference class as follows.
*/
int k;
double sin() ,cos();
main(){
float A=0, B=0, i, j, z[1760];
char b[1760];
printf("\x1b[2J");
for(; ; ) {
memset(b,32,1760);
memset(z,0,7040);
for(j=0; 6.28>j; j+=0.07) {