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
M = [13023, 201527, 4294967291] | |
N = [ | |
21179556,5337795,18437072, | |
11383457,16076557,13286032, | |
37655692,471675,21030418, | |
33533337,9666873,6884524,111490, | |
18371648 | |
] | |
mm = "" |
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
; So... what would happen if the compressed size mismatches | |
; uncompressed size in a *compressed* file? Let's find out! | |
; Note, there are three variants here: | |
; A - only Local File Header has mismatched sizes. | |
; B - only Central Directory has mismatched sizes. | |
; C - both have mismatched sizes. | |
; | |
; This is variant: A | |
; | |
; by gynvael.coldwind//vx |
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
[bits 16] | |
[org 0x0] | |
%define SEGMENT_PHYSICAL_ADDR 0x20000 | |
%define SEGNO(segno,ti,rpl) (segno*8+ti*4+rpl) | |
%define PADDR(a) (a+SEGMENT_PHYSICAL_ADDR) | |
%define PEIMAGE_PADDR 0x20200 | |
%define IDOSH_LFANEW 0x3C | |
%define IOPTH_IMGSIZE 0x50 | |
%define IOPTH_IMGBASE 0x34 |
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
gynvael:haven-windows>nasm test.asm -f win64 -o test.obj && gcc test.obj | |
gynvael:haven-windows>a.exe | |
// this actually shows the message box | |
gynvael:haven-windows>gcc --version <----------------------------- make sure you have a 64-bit mingw gcc | |
if you don't, go to [1] and get mingw-w64-install.exe file | |
gcc (x86_64-posix-seh-rev0, Built by MinGW-W64 project) 8.1.0 | |
Copyright (C) 2018 Free Software Foundation, Inc. |
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 | |
N=15 | |
fib = [0, 1] | |
for i in xrange(2, N + 2): | |
fib.append(fib[i-1] + fib[i-2]) | |
del fib[0] | |
del fib[0] | |
print fib |
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
#include <cstdio> | |
#include <iostream> | |
#include <string> | |
class Rectangle { | |
private: | |
int a; | |
int b; | |
public: |
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
generalnie jeśli chodzi o szukanie rzeczy do assemblera, to musisz zdecydować się na 3 rzeczy: | |
1) architekturę | |
2) system operacyjny | |
3) konkretny assembler | |
i szukać tutoriali pod te 3 rzeczy | |
1) w Twoim wypadku to x86-64 aka AMD64 aka x64 | |
aka 86 64-bit | |
2) hmmm Linux? czy Windows? jak wolisz? | |
[dla linuxa] | |
3) do wyboru jest nasm, yasm albo gnu as |
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
#!/usr/bin/python3 | |
""" | |
Results: | |
--- Remove if number is evenly dividable by 2 | |
1.2708177 | |
1.2841774 | |
0.667672 | |
--- Remove if number is evenly dividable by 3 |
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 json | |
import jsonschema | |
schema = { | |
"$schema": "http://json-schema.org/draft-07/schema#", | |
"type": "object", | |
"properties": { | |
"type": { | |
"type": "string", | |
"enum": [ "tens", "hundreds" ] |
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
#include <Windows.h> | |
#include <stdio.h> | |
#include <string> | |
using std::string; | |
void testdev(string devname) { | |
string path = "\\\\?\\Global\\GLOBALROOT\\Device\\" + devname; | |
printf("----------------- %s\n", devname.c_str()); |
OlderNewer