Skip to content

syntastical/msu-is4gt-ai-2020

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Description

Nest framework TypeScript starter repository.

Installation

$ npm install

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod

Test

# unit tests
$ npm run test

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

Schedule

Day 1

  1. Get everyone up and running with tic-tac-toe project
  2. Talk about git/github
  3. Cover Javascript fundamentals
  4. Start coding

Day 2

  1. Open the floor to questions
  2. Show example code and talk about other possible implementations
  3. Try to get code complete on tic-tac-toe
  4. Minimax function
    1. depth/timing
    2. https://en.wikipedia.org/wiki/Minimax
    3. alpha/beta pruning (https://en.wikipedia.org/wiki/Alpha%E2%80%93beta_pruning)
  5. Start working on battle1 project

Day 3

  1. https://flappybird.io/
  2. Attempt to finish work on battle1

Day 4

  1. http://www.gameaipro.com/GameAIPro/GameAIPro_Chapter09_An_Introduction_to_Utility_Theory.pdf
  2. Start work on battle2
  3. https://www.tensorflow.org/js/demos

Javascript

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference

Data types

String

let x = 'I am a string'
let x = "I am also a string"

Number

let x = 1
let x = 2.123

Array

let x = [1, 2, 3, 4]
let x = ['a', 'b', 'c', 'd']
let x = [
  [1, 2, 3, 4],
  [5, 6, 7, 8]
]

Object

let x = {
  name: "value",
  name1: "value1",
  pancake: [
    "wonderful",
    "tasty"
  ],
  myKey: {
    name: "name"
  }
}

Control blocks

If Statements

if(x == "hello") {
  alert("the string x is equal to hello")
} else {
  alert("the string doesn't equal hello")
}

For Loops

let x = [1, 2, 3, 4]
for(let y = 0; y < 4; y++) {
  alert(x[y]) // 2
}

Functions

Functions are reusable pieces of code that can be called with input and return values

This function takes one parameter and doesn't return any value

function myFunction(name) {
  alert("hello " + name )
}

This function takes no parameters and returns a string value

function myFunction() {
  return "my string return value";
}

Assign a function to a variable, then call it

let x = function() {
  alert("I've been called!!!");
}
x();

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published