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
<Window x:Class="WpfApplication1.MainWindow" | |
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
xmlns:wf="clr-namespace:System.Windows.Forms;assembly=System.Windows.Forms" | |
Title="MainWindow" Height="350" Width="525"> | |
<Grid x:Name="MyGrid"> | |
<Grid.RowDefinitions> | |
<RowDefinition Height="*"/> | |
<RowDefinition Height="*"/> | |
</Grid.RowDefinitions> |
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
namespace SFMLNetBitmapFont | |
{ | |
using System; | |
using SFML.Graphics; | |
using SFML.System; | |
public class BitmapFont : IDisposable | |
{ | |
private const int StartPixel = 3; | |
private const int NumAsciiChars = 256; |
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
<?xml version="1.0" encoding="utf-16"?> | |
<AnimationPackage xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | |
<SourceImagePath>Images/link.png</SourceImagePath> | |
<Sprites> | |
<Sprite SpriteIndex="0" SourceX="33" SourceY="476" Width="31" Height="36" /> | |
<Sprite SpriteIndex="1" SourceX="1553" SourceY="635" Width="40" Height="19" /> | |
<Sprite SpriteIndex="2" SourceX="17" SourceY="1586" Width="37" Height="46" /> | |
<Sprite SpriteIndex="3" SourceX="563" SourceY="856" Width="17" Height="26" /> | |
<Sprite SpriteIndex="4" SourceX="979" SourceY="1682" Width="29" Height="20" /> | |
<Sprite SpriteIndex="5" SourceX="425" SourceY="34" Width="31" Height="35" /> |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<style> | |
table, th, td { | |
border: 1px solid black; | |
border-collapse: collapse; | |
} | |
th, td { | |
padding: 5px; |
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
<Window x:Class="SfmlWpfDemo.MainWindow" | |
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
xmlns:sfmlWpfDemo="clr-namespace:SfmlWpfDemo" | |
Title="SFML + WPF Demo" Height="350" Width="525"> | |
<Grid> | |
<Grid.RowDefinitions> | |
<RowDefinition Height="2*"/> | |
<RowDefinition Height="*"/> | |
</Grid.RowDefinitions> |
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 RPi.GPIO as GPIO | |
import time | |
# set the board mode then print it | |
def set_board(bcm_mode): | |
if bcm_mode: | |
# goes by label of the pin | |
GPIO.setmode(GPIO.BCM) | |
print('using BCM mode') | |
else: |
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
# run this first | |
import praw | |
from bot_config import * | |
r = praw.Reddit('OAuth getter for wizards_to_imgur script') | |
r.set_oauth_app_info(client_id=reddit_client_id, | |
client_secret=reddit_client_secret, | |
redirect_uri=reddit_redirect_uri) | |
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
__author__ = 'travisl' | |
# This is an implementation of Langton's ant, written in Python using SFML | |
# Wikipedia article: http://en.wikipedia.org/wiki/Langton%27s_ant | |
import sfml as sf | |
UP = 0 | |
RIGHT = 1 | |
DOWN = 2 |
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 <iostream> | |
#include <ctime> | |
int CountZeroes(int n); | |
int CountFivesInFactorization(int n); | |
bool IsPrime(int n); | |
int main() | |
{ | |
int n = 0; |
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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
namespace PrimeFactorization | |
{ | |
class Program | |
{ |