Adding Path to Environment in Ubuntu
After adding some software or programing language or whatever to ubuntu, mostly using the non-synaptic method, our command line would crave for the new terms ;).
Here is how to add the new path to the environment
Lets use how to add the tomcat app server after we install it using the tar file.
1. Open the terminal : Application->Accessories->Terminal
2. use your favorite text editor to open /etc/environment in my case I would use view as vi /etc/environment
3. add the path on new line as CATALINA_HOME=”path/to/catalina”
4. save and exit!!
In most cases, the current shell would not see the effect and you may want to open another tab for that or you can use the export command
if we are appending to the existing path variable, we can use the export command as
export PATH = ${PATH}:/path/to/new/location – here the ${PATH} would maintain the existing path information and the colon would be the separator for the paths
See how you would solve these known algorithm problems
Get maximum occurring characterKadane’s algorithm in C – Dynamic Programming
Find the first occurence of number in the sorted array
Implement Queue Using two Stacks – JavaScript algorithm
binary tree problems with solution
Finding missing numbers from billion sequential number list file
Implementing tokenizer and adding tokens to the linked list
Array reversal in Recurrsion
Find K Complementary numbers from array Java implementation
Java solution for checking anagram strings – tell if phrases are anagrams