Skip to content

Instantly share code, notes, and snippets.

@esbanarango
Created December 21, 2016 16:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save esbanarango/ffe8516cabfeda9091e0bec4c829899f to your computer and use it in GitHub Desktop.
Save esbanarango/ffe8516cabfeda9091e0bec4c829899f to your computer and use it in GitHub Desktop.
#include <map>
#include <set>
#include <list>
#include <cmath>
#include <ctime>
#include <deque>
#include <queue>
#include <stack>
#include <string>
#include <bitset>
#include <cstdio>
#include <map>
#include <limits>
#include <vector>
#include <climits>
#include <cstring>
#include <cstdlib>
#include <fstream>
#include <numeric>
#include <sstream>
#include <iostream>
#include <algorithm>
#include <unordered_map>
using namespace std;
map<long long, long long> fibs;
long long hackonacci(long long n){
if(fibs.count(n)){
return fibs[n];
}else{
fibs[n] = hackonacci(n-1)+(2*hackonacci(n-2))+(3*hackonacci(n-3));
return fibs[n];
}
}
int main(){
int n, q; cin >> n >> q;
for(int a0 = 0; a0 < q; a0++){
int angle;
cin >> angle;
}
fibs[1] = 1;
fibs[2] = 2;
fibs[3] = 3;
for(long long i = 1; i <= n; i++){
for(long long j = 1; j <= n; j++){
if(hackonacci((i*j)*(i*j))%2 == 0){
printf(". ");
}else{
printf("Y ");
}
}
printf("\n");
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment