How to Make a Program Using Notepad
Write code for any language., Save the file in the correct format., Consider a more robust editor., Learn basic Batch commands., Write a basic backup program., Write a batch file to test your network., Save your file as a BAT file., Create your own...
Step-by-Step Guide
-
Step 1: Write code for any language.
Since Notepad is a plain text editor, you can use it to write code for any language, from C to HTML.
You can open Notepad from the Accessories folder in your Start menu, or by searching for "notepad".
In the sections below, you will find some basic examples for a few different programming languages. -
Step 2: Save the file in the correct format.
If you want to use your code in the compiler or interpreter for the language you are programming in, you will need to save the file in the language's format.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension for the language you are writing. , While you can certainly write entire programs in Notepad, it's definitely not the easiest way.
Notepad doesn't contain any syntax highlighting or indentation options, making it difficult to use for writing larger pieces of code.
Consider a program such as Notepad++, which is designed around programming syntax and is also free. , Notepad is most commonly used to create Batch files.
Batch files are programs used to automate functions through the command prompt.
You can use batch files to apply changes to a number of files at once, create backup systems, and more.
Below are a few basic Batch file examples. , This is a simple program that can backup files from one folder to another, only backing up files that have been modified since the last backup. , If you find yourself testing networks and internet connectivity often, this batch file will quickly display the IPConfig and Ping information for you. , When writing a Batch file in Notepad, you will want to save it as a .BAT file.
This will change the file into a Batch file that can be executed by double-clicking it or running it from the command prompt.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension ".bat" at the end of the file.
When you save it, the file will turn into a Batch file, allowing you to run it. , There is a lot that you can do with Batch files.
You can add delays, make a program for compressing files, add a password, and much more.
See this guide for more details on creating Batch files. , Python is a popular programming language for web scripting, and is one of the easier languages to learn.
Python programs don't need to be compiled; you just need the interpreter installed on your system.
Most Python programs are run through the command line interface.
Below are a few basic Python file examples. , This is one of the easiest programs to create and teaches you the basics of constructing programs in Python.
It simply displays the phrase "Hello, World!" on the user's screen. , This simple program will calculate Fibonacci numbers up to
100.
You can change the 100 value in the second line to whatever you'd like to change the number of results you get.
Make sure to include the indentations, as that is how Python designates functions. , You do not need to compile Python programs in order to run them.
If you have a Python interpreter installed on your system, you can simply run the saved Python file to execute the program.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension ".py" and save the file.
This will allow your Python interpreter to open the file. , Even though it's a fairly simple language, Python is very powerful and you can make a lot of useful stuff with it.
You can create lists, loops, and graphing charts.
You can even make games using Python.
See this guide for more details on learning the Python language. , C is one of the older programming languages around, and is the base for many of the more popular languages being used currently, such as C++ and Objective-C.
Below are a few basic C file examples. , This is one of the easiest programs to create and teaches you the basics of constructing programs in C.
It simply displays the phrase "Hello, World!" on the user's screen.
Make sure to include the indentations, as they denote functions. , Much of what you'll be doing in C involves taking and manipulating user input.
This basic program allows you to take a number and store it as a variable, which is the first step towards constructing larger programs. , C requires a compiler in order to turn the code into a working program.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension ".c" and then save the file.
This will allow you to open it in your compiler. , This is the very tip of the iceberg when it comes to C, which is a very powerful programming language.
There is a lot you can do with C programs: you can compare strings, delay the program, make an alert, and much more.
See this guide for more details on programming in C. , It's probably the most simple language so far out there.
Below comes a few examples , As it sounds, it's literally "print Hello World" (without quotes) you type. , Read it first, and save it to a variable, then extract the value of the variable and print it. , Krake doesn't require any compiling.
Just save and run it. , As you can see our previous example worked good, but no line breaks.
That's because "print" prints HTML4, and we'd need to type "<br />" instead of lines.
Learn Krake at their official website or our article -
Step 3: Consider a more robust editor.
-
Step 4: Learn basic Batch commands.
-
Step 5: Write a basic backup program.
-
Step 6: Write a batch file to test your network.
-
Step 7: Save your file as a BAT file.
-
Step 8: Create your own Batch files.
-
Step 9: Learn basic Python scripting.
-
Step 10: Create a "Hello
-
Step 11: World" program.
-
Step 12: Print the Fibonacci sequence.
-
Step 13: Run your programs.
-
Step 14: Create more Python programs.
-
Step 15: Learn basic C coding.
-
Step 16: Create a "Hello
-
Step 17: World" program.
-
Step 18: Create a program that stores user input.
-
Step 19: Compile your programs.
-
Step 20: Create more programs.
-
Step 21: Learn Krake.
-
Step 22: Print "Hello World" to the screen!
-
Step 23: Print out the contents of a file!
-
Step 24: Run the program.
-
Step 25: Create more!
Detailed Guide
Since Notepad is a plain text editor, you can use it to write code for any language, from C to HTML.
You can open Notepad from the Accessories folder in your Start menu, or by searching for "notepad".
In the sections below, you will find some basic examples for a few different programming languages.
If you want to use your code in the compiler or interpreter for the language you are programming in, you will need to save the file in the language's format.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension for the language you are writing. , While you can certainly write entire programs in Notepad, it's definitely not the easiest way.
Notepad doesn't contain any syntax highlighting or indentation options, making it difficult to use for writing larger pieces of code.
Consider a program such as Notepad++, which is designed around programming syntax and is also free. , Notepad is most commonly used to create Batch files.
Batch files are programs used to automate functions through the command prompt.
You can use batch files to apply changes to a number of files at once, create backup systems, and more.
Below are a few basic Batch file examples. , This is a simple program that can backup files from one folder to another, only backing up files that have been modified since the last backup. , If you find yourself testing networks and internet connectivity often, this batch file will quickly display the IPConfig and Ping information for you. , When writing a Batch file in Notepad, you will want to save it as a .BAT file.
This will change the file into a Batch file that can be executed by double-clicking it or running it from the command prompt.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension ".bat" at the end of the file.
When you save it, the file will turn into a Batch file, allowing you to run it. , There is a lot that you can do with Batch files.
You can add delays, make a program for compressing files, add a password, and much more.
See this guide for more details on creating Batch files. , Python is a popular programming language for web scripting, and is one of the easier languages to learn.
Python programs don't need to be compiled; you just need the interpreter installed on your system.
Most Python programs are run through the command line interface.
Below are a few basic Python file examples. , This is one of the easiest programs to create and teaches you the basics of constructing programs in Python.
It simply displays the phrase "Hello, World!" on the user's screen. , This simple program will calculate Fibonacci numbers up to
100.
You can change the 100 value in the second line to whatever you'd like to change the number of results you get.
Make sure to include the indentations, as that is how Python designates functions. , You do not need to compile Python programs in order to run them.
If you have a Python interpreter installed on your system, you can simply run the saved Python file to execute the program.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension ".py" and save the file.
This will allow your Python interpreter to open the file. , Even though it's a fairly simple language, Python is very powerful and you can make a lot of useful stuff with it.
You can create lists, loops, and graphing charts.
You can even make games using Python.
See this guide for more details on learning the Python language. , C is one of the older programming languages around, and is the base for many of the more popular languages being used currently, such as C++ and Objective-C.
Below are a few basic C file examples. , This is one of the easiest programs to create and teaches you the basics of constructing programs in C.
It simply displays the phrase "Hello, World!" on the user's screen.
Make sure to include the indentations, as they denote functions. , Much of what you'll be doing in C involves taking and manipulating user input.
This basic program allows you to take a number and store it as a variable, which is the first step towards constructing larger programs. , C requires a compiler in order to turn the code into a working program.
Click File → Save As.
In the "Save as type" drop-down menu, select "All files (*.*)".
Enter the extension ".c" and then save the file.
This will allow you to open it in your compiler. , This is the very tip of the iceberg when it comes to C, which is a very powerful programming language.
There is a lot you can do with C programs: you can compare strings, delay the program, make an alert, and much more.
See this guide for more details on programming in C. , It's probably the most simple language so far out there.
Below comes a few examples , As it sounds, it's literally "print Hello World" (without quotes) you type. , Read it first, and save it to a variable, then extract the value of the variable and print it. , Krake doesn't require any compiling.
Just save and run it. , As you can see our previous example worked good, but no line breaks.
That's because "print" prints HTML4, and we'd need to type "<br />" instead of lines.
Learn Krake at their official website or our article
About the Author
Thomas Mendoza
Enthusiastic about teaching cooking techniques through clear, step-by-step guides.
Rate This Guide
How helpful was this guide? Click to rate: