As you say, there are no hard definitions for these design patterns, having said that, from my understanding the major difference between MVC and MVP / MVVM is where the the View get's it's model data from. Whereas in MVC the View would have a reference to a Model from which it accesses it's data, in MVP the model is hidden behind the Presenter, so the data is provided through the Presenter to the View.
MVC diagram: http://www.tutorialsteacher.com/Content/images/mvc/mvc-architecture.png
Because of this, the responsibility of formatting the Model's data (if required) into something that can be displayed is the responsibility of the Presenter, which minimises the amount of business rules defined in the View and Model classes, which in turn make the Presenter a prime candidate for unit testing.
Well, module.exports
is actually not a pure JavaScript, but rather node.js feature. You can read more on what it is and how it's used here. But in general, assign to it the thing (or object of things) you want your module to export. Nothing else will make it out, which is kinda useful to isolate some globals in the module itself. And once you put var moduleSomething = require(your.module);
somewhere else, that variable will become the object you assigned to module.exports
in your.module
module.
So, basically, require
fetches the object (or whatever else you have) that is assigned to module.export
in your module file.
Unfortunately that's about as much as I can help you with your quest, since I've only been playing Screeps like 3 days so far, and not overly familiar with anything outside of my own room. But hey, at least my creep population is thriving.
On a phone so can't help much on code. You should check out documentation on for loops for c#.
http://www.tutorialsteacher.com/csharp/csharp-for-loop
Don't wanna be that guy but you should probably start a bit smaller in programming than game dev, start with a few example command line apps like a gas station pump (select gas grade, insert money by denomination, output number of gallons purchased, etc) before diving into game engines.
Protractor test automation tool plays an essential part in the Testing of AngularJS applications and fills in as a Solution integrator joining effective advances like Selenium, Jasmine, Web driver, and so on. The protractor testing tool is planned to test AngularJS application as well as for composing automated regression tests for typical Web Applications too.
on further inspection of the question (and my not that amazing answer):
Try ArrayList:
C# has a large collection of (extension) methods for manipulating enumerable collections (IEnumerable<T>). We often refer to these collectively as Linq. You can read a beginner level tutorial here. You can also just google Linq C#.
Linq often makes nice easy to understand code. It often sometimes hides a lot of inefficiency too.
Examples:
int[] array = ...;
var sum = array.Sum(); // Sum array
var average = array.Average(); // Average array
var count = array.Count(c => c == 10); // Count instances of value 10
var large = array.Where(c => c > 10); // All elements greater than 10
var doubled = array.Select(c => c * 2); // A new list with all elements doubled
var first10 = array.Take(10); // First 10 elements
if (array.Any()) // Any elements in array?
See my first post ^ . Instead of making one string, make a collection of strings.
http://www.tutorialsteacher.com/csharp/csharp-list
Alternatively, since you're only storing text, you could using one string and just concatenate (i.e. append text). https://msdn.microsoft.com/en-us/library/ms228504.aspx
e.g.
32 Inmatning += Console.ReadLine()
Concatenation is easier if you just want to store a plain text list of objects, but if you want to add more complexity and have each "object" also possess properties (e.g. each object has a name and price) then it wouldn't work.
Does that make sense?
Start from C# 2.0 and work your way up because there're a ton of language features and imho, too many ways to do the same thing, which then leads to dialect issues when reading others' code. Anyway... start from the beginning of C# and work your way up. http://www.tutorialsteacher.com/csharp/csharp-version-history
The .NET Features are also important to know. http://csharpindepth.com/articles/chapter1/versions.aspx
You get the idea... I'm sure there are a few better sources.