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
CREATE TABLE `isimler` ( | |
`id` int(10) NOT NULL AUTO_INCREMENT, | |
`ad` varchar(255) COLLATE utf8_bin NOT NULL, | |
`cinsiyet` varchar(50) COLLATE utf8_bin NOT NULL, | |
PRIMARY KEY (`id`), | |
UNIQUE KEY `ad` (`ad`), | |
KEY `cinsiyet` (`cinsiyet`) | |
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin; | |
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
# -*- coding: utf-8 -*- | |
#def add(x, y): | |
# return x + y | |
#def sub(x, y): | |
# return x - y | |
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
alias up1="cd .." | |
# edit multiple files split horizontally or vertically | |
alias e="vim -o " | |
alias E="vim -O " | |
# directory-size-date (remove the echo/blank line if you desire) | |
alias dsd="echo;ls -Fla" | |
alias dsdm="ls -FlAh | more" | |
# show directories only | |
alias dsdd="ls -FlA | grep :*/" | |
# show executables only |
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
#!/bin/bash | |
# A simple way of connecting to SSH servers | |
# | |
# Usage: | |
# sssh host_codename [USER] | |
# | |
# Configuration file: | |
# codename host [username] | |
CONF="$HOME/.sssh_hosts" |
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
#!/bin/bash | |
macs=$(cat "$MAC_FILE") | |
if [ "$#" -lt 1 ] | |
then | |
# No arguments. List available macs | |
echo "$macs" | |
else | |
IFS=$'\n' |
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
#!/bin/bash | |
process_id=`ps aux | grep libflash | grep -v grep | tr -s " " | cut -d " " -f 2` | |
videos=`file /proc/$process_id/fd/* | grep Flash | sed -n 's,^\(/proc/[0-9]\+/fd/[0-9]\+\):\(.*\),\1,p'` | |
echo "$videos" |
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
<?php | |
class Urunler { | |
public $urunID; | |
function urunBilgisi($urunID = 123) | |
{ | |
$conn = mysql_connect('localhost','root','1234'); | |
mysql_select_db('eticaret', $conn); | |
$urunler = "SELECT * FROM tUrunler WHERE urunID = '".$urunID."'" or die(mysql_error()); | |
$q = mysql_query($urunler) or die(mysql_error()); |
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 | |
#-*- coding:utf-8 -*- | |
import sys | |
import re | |
sesli = ['a', 'e', 'ı', 'i', 'o', 'ö', 'u', 'ü', 'A', 'E', 'I', 'i', 'O', 'Ö', 'U', 'Ü'] | |
sessiz = ['b', 'c', 'ç', 'd', 'f', 'g', 'ğ', 'h', 'j', 'k', 'l', 'm', 'n', 'p', 'r', 's', 'ş', 't', 'v', 'y', 'z', 'B', 'C', 'Ç', 'D', 'F', 'G', 'Ğ', 'H', 'J', 'K', 'L', 'M', 'N', 'P', 'R', 'S', 'Ş', 'T', 'V', 'Y', 'Z' ] | |
def reg_exp(list): |
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
<section> | |
<!-- START YouTube --> | |
<article> | |
<div id="youtube"></div> | |
<footer> | |
<h3>YouTube</h3> | |
</footer> | |
</article> | |
<!-- END YouTube --> |
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/env ruby | |
(1..100).each do |i| | |
fizz = (i % 3) == 0? 1 : 0 | |
buzz = (i % 5) == 0? 1 : 0 | |
index = (buzz << 1) | fizz | |
output = [i, "Fizz", "Buzz", "FizzBuzz"] | |
puts output[index] | |
end |