Skip to content

Instantly share code, notes, and snippets.

@Skeukry
Skeukry / media_numpad.cpp
Last active April 11, 2021 18:30
Turn your numpad into media buttons! When this program is running, if you turn OFF the numlock, the following buttons will be remapped: numpad 4,6,7,8,9
// ##############################
// # Media Numpad #
// # by Ferenc Kálmán #
// ##############################
#include <windows.h>
#include <iostream>
using namespace std;
--- TLP 0.8 --------------------------------------------
+++ Configured Settings: /etc/default/tlp
TLP_ENABLE=1
TLP_DEFAULT_MODE=AC
DISK_IDLE_SECS_ON_AC=0
DISK_IDLE_SECS_ON_BAT=2
MAX_LOST_WORK_SECS_ON_AC=15
MAX_LOST_WORK_SECS_ON_BAT=60
SCHED_POWERSAVE_ON_AC=0
@Skeukry
Skeukry / atvalt.cs
Created December 4, 2016 19:51
Átváltja a {mit} számot {mibol} számrendszerből {mibe} számrendszerbe.
private static string atvalt(string mit, int mibol, int mibe)
{
int PONTOSSAG = 10;
if (mibol != 10)
{
int szorzo = 0;
int pont = Math.Max(mit.IndexOf("."), mit.IndexOf(","));
if (pont != -1)