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
ig.module('plugins.component') | |
.requires('impact.entity') | |
.defines(function () { | |
/** | |
* The base class for the components. Provides the needed stubs. | |
* @type {Component} | |
*/ | |
Component = ig.Class.extend({ |
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
*.pbxproj text -crlf -diff -merge=union |
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
/** | |
* Will convert any float (pos or neg) to an hour value | |
* floatToHour(1.5) will return "1h30" | |
* | |
* @param {number} | |
* @returns {string} | |
*/ | |
function floatToHour(num) { | |
var sign = num >= 0 ? 1 : -1; |
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
from utils import * | |
def euler1(): | |
res = 0 | |
for i in range(1000): | |
if not (i % 3 == 0 and i % 5 == 0): | |
res += i | |
return res |
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
# ---------------[ Unity generated ]------------------ # | |
Temp/ | |
Obj/ | |
UnityGenerated/ | |
Library/ | |
# ----[ Visual Studio / MonoDevelop generated ]------- # | |
ExportedObj/ | |
*.svd |
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
- (IBAction)changePage { | |
// update the scroll view to the appropriate page | |
_pageControlBeingUsed = YES; | |
CGRect frame; | |
frame.origin.x = _scrollView.frame.size.width * _pageControl.currentPage; | |
frame.origin.y = 0; | |
frame.size = _scrollView.frame.size; | |
[_scrollView scrollRectToVisible:frame animated:YES]; | |
} |
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/python | |
import subprocess | |
import os | |
import shutil | |
from datetime import datetime | |
import argparse | |
ignoreList = [".gitignore"] | |
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
DELETE mytable | |
FROM mytable | |
INNER JOIN ( | |
SELECT max(id) AS lastId, someColumnWithDupes | |
FROM mytable | |
GROUP BY someColumnWithDupes | |
HAVING count(*) > 1 | |
) duplic ON duplic.someColumnWithDupes = mytable.someColumnWithDupes | |
WHERE mytable.id < duplic.lastId; |
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
--Find Duplicates | |
SELECT t.ID, t.id_A, t.id_B | |
FROM ( | |
SELECT id_A, id_B | |
FROM table_name | |
GROUP BY id_A, id_B | |
HAVING count(*) > 1 | |
) x, table_name t | |
WHERE x.id_A = t.id_A AND x.id_B = t.id_B |