This file contains hidden or 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
| (defun custom-select-all () | |
| (interactive) | |
| ;; (message "test %s" (key-description (string (read-event nil nil 2)))) | |
| (mark-whole-buffer) | |
| (setq tmp (read-event nil nil 0.3)) | |
| (if tmp | |
| (progn | |
| (when (string= "left" tmp) | |
| (deactivate-mark) | |
| ) |
This file contains hidden or 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
| iptables -t nat -I PREROUTING -p tcp -d 1.2.3.4 --dport 80 -j DNAT --to-destination 10.0.0.1:80 | |
| iptables -t nat -I PREROUTING -p tcp -d 1.2.3.4 --dport 22 -j DNAT --to-destination 10.0.0.2:22 | |
| iptables -I FORWARD -m state -d 10.0.0.0/24 --state NEW,RELATED,ESTABLISHED -j ACCEPT |
This file contains hidden or 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
| ;; __ __ __ _ _ _ | |
| ;; | \/ |_ _ ___ _ __ ___ __ _ ___ ___ ___ ___ _ __ / _(_) __ _ _ _ _ __ __ _| |_(_) ___ _ __ | |
| ;; | |\/| | | | | / _ \ '_ ` _ \ / _` |/ __/ __| / __/ _ \| '_ \| |_| |/ _` | | | | '__/ _` | __| |/ _ \| '_ \ | |
| ;; | | | | |_| | | __/ | | | | | (_| | (__\__ \ | (_| (_) | | | | _| | (_| | |_| | | | (_| | |_| | (_) | | | | | |
| ;; |_| |_|\__, | \___|_| |_| |_|\__,_|\___|___/ \___\___/|_| |_|_| |_|\__, |\__,_|_| \__,_|\__|_|\___/|_| |_| | |
| ;; |___/ |___/ | |
| ;; | |
| ;;----------------------------------------------------------------------------------- | |
| ;; Custom variables set by Emacs | |
| ;;----------------------------------------------------------------------------------- |
This file contains hidden or 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
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <assert.h> | |
| typedef unsigned char u8; | |
| static const char *base64_table = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; | |
| int base64_lookup_character(int ch) |
This file contains hidden or 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
| factorial = (x) => | |
| { | |
| let total = 1; | |
| for(let i = 1; i <= x; i+=2) | |
| { | |
| if(i + 1 > x) | |
| total *= i; | |
| else | |
| total *= (i * (i + 1)); | |
| } |
This file contains hidden or 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
| /* | |
| Change the number between the parentheses after APP_ID to the game you want to idle. | |
| Then run the program and when you're done idling press a key. | |
| */ | |
| //730 is the AppID for CSGO | |
| //480 for Spacewar | |
| #define APP_ID (730) | |
| //Imported functions from libraries that are needed. |
This file contains hidden or 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
| #include <stdio.h> | |
| #include <stdlib.h> | |
| int to_float( int number ) | |
| { | |
| int flt = 0; | |
| if ( number < 0 ) | |
| { | |
| number = -number; |
This file contains hidden or 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
| #include <stdio.h> | |
| unsigned int u32pow( unsigned int x, unsigned int y ) | |
| { | |
| if(y == 0) | |
| return 1; | |
| for ( unsigned int i = 1; i < y; ++i ) | |
| x += x; | |
| return x; | |
| } |
This file contains hidden or 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
| global _start | |
| BITS 32 | |
| section .data | |
| string: db "Value is ", 0 | |
| newline_string: db 10, 0 | |
| section .text | |
| strlen: | |
| push ebp | |
| mov ebp, esp |
This file contains hidden or 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
| #+LaTeX_CLASS: article | |
| #+LATEX_HEADER: \usepackage[superscript,biblabel]{cite} | |
| #+TITLE: Example document | |
| #+DESCRIPTION: Description | |
| #+AUTHOR: Author | |
| * Chapter 1 | |
| Example of a list: |