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
# Package to install, to get an open terminal in Right-Click context menu. | |
sudo apt-get install nautilus-open-terminal | |
# To move window controls in your Ubuntu from left to right… | |
gconftool-2 --type string --set /apps/metacity/general/button_layout "menu:minimize,maximize,close" | |
# To switch back | |
gconftool-2 --type string --set /apps/metacity/general/button_layout "close,maximize,minimize:menu" | |
# Repeat last command with sudo | |
sudo !! |
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> | |
#define ARRAY_SIZE 15 | |
typedef enum {false, true} bool; | |
int leng(char *ipstr) | |
{ | |
int i = 0; | |
while(ipstr[i] != '\0') | |
i++; | |
return i; |
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
from math import * | |
import sys | |
chosen = {} | |
n = int(sys.argv[1]) | |
def place(xpos, ypos): | |
if (ypos in chosen.values()): | |
return False | |
opponent = 1 |