Vim not syntax highlighting in sudo/root huh..
So I had to deal with the server issue and I ssh into it. Then opened the file looked at it and wanted to change the content, I had to be on root and I noticed the syntax highlighting was off..
Here are the steps I took to check what went wrong.
Basically when I am sudo-ing the user has changed a bit. So the configuration per that user is the area of focus.
Also, there could be multiple installations and vanilla versions for the vim as well, so check which one the sudo is using
sudo which vim
I was able to locate the right vim the sudo was using and I applied that one to fix the issue
See how you would solve these known algorithm problemsCheck if two strings are anagrams or not
Java solution for checking anagram strings – tell if phrases are anagrams
Find longest palindrom from sequence of characters
Implementing tokenizer and adding tokens to the linked list
Kadane’s algorithm in C – Dynamic Programming
Array reversal in Recurrsion
Find K Complementary numbers from array Java implementation
String Ordered Permutation Algorithm Problem
Find the first occurence of number in the sorted array
testing k complementary pairs algorithm with junit