Which editor is better - VIM or EMACS ?

1 Like

Sublime Text 2 !!! :slight_smile:


The holy war of Vim v/s Emacs has reached Codechef Discuss! You can read about it on [wikipedia][1].

Personally I use Vim and find it feature complete. It is fast and robust. You can customize it using vimrc and install plugins to enhance it.

But same can be said about emacs. However the distinct advantage of vim is that it is already installed on linux machines. I happen to have worked on an old college computer with no internet, no gui. The pre-installed gcc and vi (not vim) came to my rescue!

Just use them and stick to one (or both) of them.

Recently I have started using Sublime Text 2 too and find it to be a nice editor.


“Better” is an adjective and depends on perception, so I will tell what I like, may or may not be true for others!
For me, Vim is better. I am happy and it provides me all the tasks I wanna do.

Choosing an editor doesn’t guarantee you would write better programs. :smiley:

Vim being close to the terminal, and I like to spend maximum time at the command line, is my favorite.

Attaching screenshot, just to illustrate its multi-window facilities and programmer-friendly customizability :stuck_out_tongue:


Both are good for novice and awesome for any experienced programmer. The productivity is dependent on the programmer :stuck_out_tongue: But, I favor Emacs.


Note: This wasn’t written by me, but I touched up a bit of the English.

A UNIX wizard hears cries of torment from his apprentice’s computer room where the apprentice is studying, and goes to investigate.

He finds the apprentice in obvious distress, nearly on the verge of tears. “What’s the problem?” he asks. “Why did you cry out?”

“It’s terrible using this system. I must use four editors each day to get my studies done, because not one of them does everything.”

The wizard nods sagely, and asks, “And what would you propose that will solve this obvious dilemma?”

The student thinks carefully for several minutes, and his face then lights up in delight. Excitedly, he says, “Well, it’s obvious. I will write the best editor ever. It will do everything that the existing four editors do, but do their jobs better, and faster. And because of my new editor, the world will be a better place.”

The wizard quickly raises his hand and smacks the apprentice on the side of his head. The wizard is old and frail, and the apprentice isn’t physically hurt, but is shocked by what has happened. He turns his head to face the wizard. “What have I done wrong?” he asks.

“Fool!” says the wizard. “Do you think I want to learn yet another editor?”

Immediately, the apprentice is enlightened.

Eclipse with CDT. Almost nothing can beat the full functionality of a IDE. “Almost” :stuck_out_tongue:

What do i need to install to run my c++ codes in vim ? How to install and run gcc in vim ? and how can i do the navigation in vim from one folder to other ??

To compile C++ programs, you just need to install g++. If you’re on a linux machine, then most probably it would have come with gcc already installed :slight_smile: You can check it by typing the command “gcc --version” in the terminal. If you want to write a file in some directory, you need to first change the current directory to that directory using command “cd dir_path” and then all you gotta do is type “vi filename.c” or “vi filename.cpp” to write a C program or a C++ program respectively.

1 Like