{
"build-js": "browserify browser/main.js | uglifyjs -mc > static/bundle.js",
"build-css": "cat static/pages/*.css tabs/*/*.css",
"build": "npm run build-js && npm run build-css",
"watch-js": "watchify browser/main.js -o static/bundle.js -dv",
"watch-css": "catw static/pages/*.css tabs/*/*.css -o static/bundle.css -v",
"watch": "npm run watch-js & npm run watch-css",
gulp.task('webjob', function() { | |
var webjob = "feedFetcher.zip"; | |
del(webjob) | |
return gulp.src(['parsers/*.js', 'package.json', 'feedFetcher.js'], {base: "."}) | |
.pipe(zip(webjob)) | |
.pipe(gulp.dest('.')); | |
}); |
Custom CSS checkboxes using the Font Awesome icon font
A Pen by James Barnett on CodePen.
"use strict"; | |
// Quick Arguments Shape Adapters | |
function unary(fn) { | |
return function one(arg) { | |
return fn(arg); | |
}; | |
} | |
function binary(fn) { |
Implement a Queue service in NodeJS/JAVA (or your preferred language). Implement all the features that you think should be supported by a queuing service/message broker, like:
- Receive a message.
- Store messages.
- Send messages to a consumer one-by-one or in bulk when a consumer requests messages.
- Acks and Nacks: If the consumer successfully acks the message, the message should get deleted from the queue. When a message is nacked, it should appear back in the queue to be consumed by any consumer immediately.
- Visbility timeout: If a consumer gets a message, no other consumer should see that message for
Visbility timeout
seconds. If the message is nacked/acked by this time, good enough. If not, the message should again be visible. - Deadletter settings: If the message is nacked more than a specified number of times, the message is moved to a dead letter queue.
Also create a library that contains functions to interact with the queue / manage the queue.
Incrementing Integers As A Service
User Story
As a developer, I need a way to get integers that automatically increment so that I can generate identifiers from within my code. I am in a hurry and would like to call a REST endpoint that returns the next available integer so that I can get on with building my feature. Why I need to generate identifiers using sequential integers is not important ;) Suffice it to say that this challenge is based on a real-world scenario.
Your Task
Develop a REST service that:
- Allows me to register as a user. At a minimum, this should be a REST
I hereby claim:
- I am ankitwww on github.
- I am ankitlst (https://keybase.io/ankitlst) on keybase.
- I have a public key ASBa0C4P6aEAZ3TMRmXzcHpuD8REvEZugVbont5o0Gcq0go
To claim this, I am signing this object:
[Don't comment your code here - You will be immediately disqualified]
Given an array of positive numbers and a positive number ‘k,’ find the maximum sum of any contiguous subarray of size ‘k’.
Example 1:
Input: [2, 1, 5, 1, 3, 2], k=3 Output: 9 Explanation: Subarray with maximum sum is [5, 1, 3].
[Don't comment your code here - You will be immediately disqualified]
Given an array of sorted numbers and a target sum, find a pair in the array whose sum is equal to the given target.
Write a function to return the indices of the two numbers (i.e. the pair) such that they add up to the given target.
Example 1:
Input: [1, 2, 3, 4, 6], target=6 Output: [1, 3]