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 UnityEngine; | |
using UnityEditor; | |
using System; | |
using System.Xml.Linq; | |
using System.Collections.Generic; | |
public enum MapType { | |
Isometric, | |
Orthogonal | |
} |
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 UnityEngine; | |
using System.Collections; | |
using Pathfinding; | |
// WARNING: BYDLOCODE!!!!! | |
public class EnemyController : MonoBehaviour | |
{ | |
public Path path; | |
public float moveSpeed; | |
public float nextWaypointDistance = 0.5f; |
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/ | |
Library/ | |
===================================== | |
Visual Studio / MonoDevelop generated | |
===================================== | |
Assets/UnityVS/ |
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
def get_digit_count(n): | |
digit_count = [0] * 10 | |
s = n | |
div = 1 | |
while s > 0: | |
s //= 10 | |
x = n - (div - 1) | |
full_period = x // (10 * div) | |
unfull = x % (10 * div) | |
unfull_periods = unfull // div |
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 <stdio.h> | |
long long* get_digit_count(long long n) { | |
long long* digit_count = new long long[10]; | |
long long s = n; | |
int div = 1; | |
while (s > 0) { | |
s /= 10; | |
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 | |
def get_combination_count(i): | |
global arr | |
if arr[i - 1] == -1: | |
if i <= 2: | |
arr[i - 1] = 2 | |
else: | |
arr[i - 1] = (get_combination_count(i - 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
s = input() | |
ls = len(s) | |
stack = [s[0]] | |
i = 1 | |
while i < ls: | |
if len(stack) > 0: | |
ch = stack.pop() | |
if ch != s[i]: | |
stack.append(ch) |
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
n = int(input()) | |
a = [] | |
for _ in range(0, n): | |
a.append(int(input())) | |
stack = [] | |
max_taken = 0 | |
for i in range(0, n): | |
if a[i] > max_taken: |
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
n = int(input()) | |
split_table = {} | |
def get_split_sum(a, start_index, end): | |
l = end - start_index + 1 | |
if l <= 2: | |
return 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
import math | |
angles = [] | |
n_top = 0 | |
with open("tests/01") as fi: | |
n = int(fi.readline()) | |
for _ in range(n): | |
x, y = [int(s) for s in fi.readline().split()] | |
angle = math.degrees(math.atan2(y, x)) |
OlderNewer