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
import java.util.HashMap; | |
public class SubnetCalc { | |
private static HashMap<String, IPClass> _ipClasses; | |
static { | |
_ipClasses = new HashMap<String, IPClass>(); | |
_ipClasses.put("A", new IPClass(new int[]{ 255, 0, 0, 0 })); | |
_ipClasses.put("B", new IPClass(new int[]{ 255, 255, 0, 0 })); | |
_ipClasses.put("C", new IPClass(new int[]{ 255, 255, 255, 0 })); |
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
//Required assemblies: | |
//PaintDotNet.Base | |
//PaintDotNet.Core | |
//PaintDotNet.Data | |
using PaintDotNet; | |
using System; | |
using System.Drawing; | |
using System.Drawing.Imaging; | |
using System.IO; |
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
//Based on the ACPICA source code (https://github.com/acpica/acpica) | |
namespace ASLTest.AML | |
{ | |
class OpCode | |
{ | |
public string Name; | |
public ParseArgFlags[] ParseArgs; | |
public InterpreterArgFlags[] RuntimeArgs; | |
public ObjectTypeEnum ObjectType; |
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
<activity android:name="com.google.games.bridge.NativeBridgeActivity" | |
android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen" /> |
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
//Components required: | |
//HT16K33 | |
//4 digit 7 segment display | |
//"Rotary encoder" (the 2 button version) | |
//Some pullup/down resistors for the display the the encoder | |
//Runs on: ATmega328 based boards | |
#include <ht16k33.h> |
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
private void UpdatePhysics(float dt, ref Vector2 position) | |
{ | |
//Update velocity | |
Velocity += Map.Gravity * dt; | |
Velocity.X = MathHelper.Clamp(Velocity.X, -Map.MaxVelocity.X, Map.MaxVelocity.X); | |
Velocity.Y = MathHelper.Clamp(Velocity.Y, -Map.MaxVelocity.Y, Map.MaxVelocity.Y); | |
//Check collision | |
float corr; |
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
using Microsoft.Xna.Framework; | |
namespace Tools | |
{ | |
public static class Extensions | |
{ | |
public static float DeltaTime(this GameTime time) | |
{ | |
return (float)time.ElapsedGameTime.TotalSeconds; | |
} |
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
#ifdef DEBUG | |
#include "OutputInterceptor.h" | |
#include <iostream> | |
#include <string> | |
#include <sstream> | |
using namespace std; |
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
while (!::IsDebuggerPresent()) | |
::Sleep(100); | |
::DebugBreak(); |
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 Irvine32.inc | |
ExitProcess proto,dwExitCode:dword | |
; Adat | |
.data | |
Str_Mode DB "Kodolas vagy dekodolas? K/D ", 0 | |
Str_Shift DB "Eltolas? ", 0 | |
Str_Code DB "Szoveg? ", 0 | |
Str_Result DB "Kimenet: ", 34, 0 ; 34 = " | |
Str_Quote DB 34, 0 ; Egy idézőjel |
OlderNewer