Looking for good programming challenges?

Use the search below to find our solutions for selected questions!

Archive for November 2016

Finding n-th permutation without computing others

Given S of size n and k, return the kth lexicographic permutation sequence. (Note: Given n will be between 1 and 10 inclusive.) For n = 10 variable symbols we have 10! possible permutations. The first step is to find the first symbol. If we fix a first symbol, then . . . Read more

Build WAR file with Maven and deploy with Ant

Minimalistic Ant script for Tomcat war file deployment. This script first does a mvn clean and mvn install on the defined maven project. It then connects to the provided server, stops the running Tomcat, uploads the newly created .war file to the Tomcat’s webapp directory and starts the Tomcat again. . . . Read more