Deployment is the hardest part in the lives of computer coders, it's harder than making apps and games. Any game that you have ever used for example on your computer had to go through many operations to be in the final form it is when you first bought it. The last operation is deployment as you might have guessed. It's about getting your video game ready to use and play on any computer out there. Many issues could happen while deploying the game since we have many environments to deal with these days.
Big O Notation is a mathematical expression that describes how much time an algorithm takes to run according to the size of it's inputs; mostly concerned about the worst case scenario. Types: 1- Constant Time O(1): On this order, regardless of the number of items, the iterations(time) are constant. Example: const getFirstItem = items => items[0]; getFirstITem([1, 2, 3, 4]); // 1 (one iteration) getFirstItem(['b', 'd', 'g']); // 'b' (one iteration) 2- Linear Time O(n): On this order, the worst case grows with the number of items. Example: Javascript's built in function indexOf, it loops over an array to find the correct index of the passed element. The worst case is looping over the whole array. [1, 2, 4, 9, 23, 12].indexOf(12); 3- Quadratic Time O(n ^ 2): For this order, the worst case time is the square of the number of inputs. It grows exponentially according to the number of inputs. Example: Using nested loo...
Comments
Post a Comment