Skip to content

Instantly share code, notes, and snippets.

View aershov24's full-sized avatar
🇦🇺

Alex Ershov aershov24

🇦🇺
View GitHub Profile
@aershov24
aershov24 / openuv.js
Last active March 10, 2018 03:10
NodeJS Client module for OpenUV - Global Real-Time UV Index API
/*
NodeJS Client module for OpenUV - Global Real-Time UV Index API
Installation:
npm install --save request
npm install --save query-string
Usage:
const openuv = require('./openuv.js')('v1', 'YOUR_API_KEY');
## 10 Hardest Angular Interview Questions
Learn one way to build applications with Angular and reuse your code and abilities to build apps for any deployment target. For web, mobile web, native mobile and native desktop.
##### *Q1*: What is difference between Git vs SVN?
**Difficulty:** ⭐
The main point in Git vs SVN debate boils down to this: Git is a distributed version control system (DVCS), whereas SVN is a centralized version control system.
**Source:** [medium.com](https://medium.com/@gauravtaywade/15-interview-questions-about-git-that-every-developer-should-know-bcaf30409647)
##### *Q2*: What is the command to write a commit message in Git?
**Difficulty:** ⭐

25 Redis Interview Questions (ANSWERED) For Web Developers

Redis offers a great deal of support for developing efficient caching mechanisms. It takes only a couple of minutes to implement a cache mechanism and get it working with any application. Follow along to learn 25 most common Redis Interview Questions and Answers for your next senior web developer interview.

Q1: What is Redis?

Topic: Redis
Difficulty: ⭐

Redis, which stands for Remote Dictionary Server, is a fast, open-source, in-memory key-value data store for use as a database, cache, message broker, and queue.

You can run atomic operations, like appending to a string; incrementing the value in a hash; pushing an element to a list; computing set intersection, union and difference; or getting the member with highest ranking in a sorted set.

@aershov24
aershov24 / Markdium-text.txt
Created September 23, 2020 05:52
Markdium-
public void Consumer()
{
foreach(int i in Integers())
{
Console.WriteLine(i.ToString());
}
}
public IEnumerable Integers()
{
@aershov24
aershov24 / Markdium-text.txt
Created September 23, 2020 05:52
Markdium-
public static IEnumerable Where(this IEnumerable items, Predicate< T> prodicate)
{
foreach(var item in items)
{
if (predicate(item))
{
// for lazy/deffer execution plus avoid temp collection defined
yield return item;
}
}
@aershov24
aershov24 / Markdium-text.txt
Created September 23, 2020 05:52
Markdium-
var anonymousData = new
{  
    ForeName = "Jignesh",  
    SurName = "Trivedi"
};  
Console.WriteLine("First Name : " + anonymousData.ForeName);
@aershov24
aershov24 / Markdium-text.txt
Created September 23, 2020 05:52
Markdium-
string place = "world";
@aershov24
aershov24 / Markdium-text.txt
Created September 23, 2020 05:52
Markdium-
string greet = String.Format("Hello {0}!", place);
@aershov24
aershov24 / Markdium-text.txt
Created September 23, 2020 05:52
Markdium-
public class TweetsController : Controller {
// GET: /Tweets/
[HttpGet]
public ActionResult Index() {
return Json(Twitter.GetTweets(), JsonRequestBehavior.AllowGet);
}
}
@aershov24
aershov24 / Markdium-text.txt
Created September 23, 2020 05:52
Markdium-
public class TweetsController : ApiController {
// GET: /Api/Tweets/
public List Get() {
return Twitter.GetTweets();
}
}