Word is the best code editor



Many of you may be surprised by the title, as there are many code editors such as VS CodeVisual StudioJetBrains editorsNetbeans …., that contain many tools and features that help in writing the code, or perhaps wondering is it possible to write the code in Word files, compile it and run it??
This is what we will explain in this article.

Is There Differences Between The Editor And Compiler?

First of all, let’s agree that a code editor is different from a code compiler.
Let’s explain more by giving a clear definition of each term so that you can agree on the difference between them.

The Editor: is just a program in which you write and edit the
program.

The Compiler: is used to compile the program, and convert
the program to machine understandable code.

There is another term we should know about it which is the IDE (Integrated Development Environment)

The IDE: is a development environment that often combines both (Editing and Compiling the code) into an intelligent application.

Many of you may say that the Word is not a code editor but a text editor, basically, all the IDEs that you use to write the code it’s a text editors with the ability to compile the code, and many tools that could help you when you write the code (Debugging tools, give suggestions, needed packages of the programming language you use, …).

So when we write the code on Word it’s not enough we need one more step which is compiling the code compiling, that we can achieve it by the Command Prompt on Windows or on the Terminal on Mac, by installing the required packages for the specific programming language to compile the code.

In another word we can say after writing the code as text on the Word program we can get the Word file where we write the code and compile it on the OS terminal in order to get the result.


Why The Word Is The Best Code Editor For Me?

Byusing the Word program to write the code, you can write the code in the form you want and modify it by controlling the text color, font size, and code arrangement, using templates, and much more …




Steps To Write The Code On Write And Compile It On Terminal:

If you feel more comfortable watching a video explaining the steps with explaining the differences between the Compiler and the Assembler, you can watch my youtube video to get more fun and info.



  1. First, write the code that you want to compile on a word file.
  2. Then save it as plain text and don’t forget to check MS-DOS and Allow Character Substitution and click ok.
  3. The weird thing is you can’t give the file java suffix from the first time so you have to save it again with java suffix and save it in the same way with plain text and check the MS-DOS and allow Character Substitution again, Click ok and go to the CMD.
  4. In order to execute the java code you have to install the JDK which is (Java development tools) on your machine to be able to compile the java code that we have, (You can install the required packages to compile the code depending on the programming language that you used it to write the code on Word), And here is the idea that I wanted to clarify by writing the code in the Word, in order to prove that the Compiler is not the editor when we write the code, but rather the Compiler is a program that translates this code from a programming language into a machine language in order to execute it.
  5. Let’s type javac to compile the code.
  6. Then type java with the file name to execute the file as well.

Finally, we got the idea that is possible to write the code on any text editor you want and the differences between the IDE and the text editor, I hope it was useful and fun for you.


Comments

Popular posts from this blog

Tic Tac Toe

Angry Birds Using Unity 2D