Skip to content

Instantly share code, notes, and snippets.

// replace all -1 with 0
for i in 0..input.len() {
for j in 0..input[i].len() {
if input[i][j] == -1 {
input[i][j] = 0;
}
}
}
// check if any greater than 9, set them to -1
// and call update on valid neighbours and diagonals
for i in 0..input.len() {
for j in 0..input[i].len() {
if input[i][j] > 9 {
input[i][j] = -1;
if i > 0 {
input[i - 1][j] = update(input[i - 1][j]);
}
// check if any greater than 9, set them to -1
// and increase neighboring and diagonal numbers
for i in 0..input.len() {
for j in 0..input[i].len() {
if input[i][j] > 9 {
input[i][j] = -1;
if i > 0 {
input[i - 1][j] += 1;
}
if i < input.len() - 1 {
asdasd
We can't make this file beautiful and searchable because it's too large.
# Copyright 2017 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
import tensorflow as tf
import sonnet as snt
# Helper libraries
import numpy as np
import os
import sys
from absl import flags
from absl import app
#include <iostream>
#include <SDL.h>
#include <bgfx/bgfx.h>
#include <bx/math.h>
struct PosColorVertex
{
float x;
#include <iostream>
#include <SDL.h>
#include <bgfx/bgfx.h>
#include <bx/math.h>
struct PosColorVertex
{
float x;