Date: November 29, 2020
To: Students in computer science major of City College of New York
From: Xiaohu Zheng, student of CCNY
Major in computer science
Subject: Proposal for using visual studio to code
The purpose of this proposal is to let the students in computer science major to know the advantages of Microsoft’s Visual Studio IDE and to persuade them to use visual studio for coding.
With the rapid development of computer technology, many students are required to take at least one coding course for college requirements. Leaning how to code can be extremely difficult and annoying, so that many people need a huge amount of time to learn how to code.
Currently, CCNY has no formal policy on what IDEs/Text Editors student should use to code. By default, students can freely use any tools to code with no restriction. After 3 months observation, I found many students in my CS class are not using visual studio to code. And even most of them are using text editors or online compilers. This is simply not a good way to learn the programming language because text editors/online compilers require programmers to be sophisticated at the language, so they don’t provide any recommendations/debug tools while coding. When programmers don’t know where the bug is, it can cost them a huge amount of time to debug and fix the code.
Therefore, I want to recommend Microsoft’s Visual Studio IDE to the CS students at CCNY. More specifically, I will introduce what is Visual Studio and the functionalities and advantages of visual studio. I will talk about the cost of downloading Visual Studio and the time of learning Visual Studio.
I propose CS students at CCNY to download visual studio and use visual studio to code for their homework projects. In order to show the advantages of Visual studio, I will conduct primary and secondary research. I will provide information along with pictures to show how convenient visual studio is. By proving visual studio is a decent tool, this proposal will provide the evaluation of visual studio from University of South Florida and a study of visual studio. Comparison between Visual Studio and other tools will also be made. This proposal will only discuss Visual Studio Community, which is a free version
At the end of the discussion, this proposal will also present the weakness of Visual Studio, which is an unavoidable factor, so that the readers will have a better understanding of Visual Studio.
After seeing many of my classmates are struggling with coding, I have decided to introduce Microsoft’s Visual Studio IDE to the CS students at CCNY.
Currently, CCNY has no formal policy on what IDEs/Text Editors student should use to code. By default, students can freely use any tools to code with no restriction. After 3 months observation, I found many students in my CS class are not using visual studio to code. And even most of them are using text editors or online compilers. This is simply not a good way to learn the programming language because text editors/online compilers require programmers to be sophisticated at the language, so they don’t provide any recommendations/debug tools while coding. When programmers don’t know where the bug is, it can cost a huge amount of time to debug and fix the code.
Therefore, I want to recommend Microsoft’s Visual Studio IDE to the CS students at CCNY. More specifically, I will introduce what visual studio IDE is and the four advantages of visual studio:
- Auto-Complete and auto-adjust (IntelliSense)
- Error tracking
- Separating files and color difference
In the following sections, I will explain what Visual studio IDE is and compare it with text editors. I will provide more details of each tool along with pictures and explain why it is better. Then, the rest we will briefly discuss the cost and the disadvantage.
What is visual studio IDE?
In order to know what visual studio is, we first need to know what IDE is. IDE stands for Integrated Development Environment. The article “A Study of Visual Studio Usage in Practice” describes that “Integrated Development Environments (IDEs) provide a convenient standalone solution that supports developers during various phases of software development.” (Amann et al., 2016) Generally, an IDE provides different tools such as text editor, debugger and compilers. One more useful feature that I need to mention is that IDEs usually support different languages. As new programmers, we might start learning only one programming language, but this feature is actually very helpful in future study. With all the features together, we can conclude that programmers can do any tasks on an IDE.
Visual Studio is an IDE as you can tell from its name. “Visual Studio includes compilers, code completion tools, graphical designers, and many more features to ease the software development process.” (Terry G et al, 2019) As we can see, Visual studio is a strong coding tool developed by Microsoft. We will discuss the useful features of Visual Studio now.
Features of Visual Studio
In this section, we will focus on four useful tools that visual studio provides. And we will compare them with online compilers and normal text editors. We will show examples and analyze the implementations of each example.
Tool 1. IntelliSense – Autocomplete and auto-adjust
|Text Editor||Online Complier||Visual Studio|
All three files have exactly the same amount of typing times, but visual studio is already a few lines ahead! The text editor shown in figure 1 is really fundamental but useless. Figure 2, an online complier looks better that it provided some tools but not enough. The code in visual studio is elegant and CORRECT!
First, notice the line 1 at figure 3, Visual studio has line “#pragma once”. This line is needed because complier will not declare the class again if it is already declared somewhere else. Without this line, the program will probably give compiling error. If the programmer doesn’t know where the mistake is, it will take him/her at least a few hours to fix it with a text editor/online complier. If the programmer made the same mistake with visual studio, this would only take him a few seconds even if he didn’t know where the bug is.
Let me introduce another bug at the last line of figure 2 and figure 3. Visual studio has one more semicolon (;). This MUST be included in a class definition because the program will give compiling error without it. If you use visual studio, you don’t have to deal with all these minor bugs, so that you can spend your time on something more important like algorithms and data structures.
Semicolon in visual studio will help programmers to format. If one types “testExp=1” followed by the semicolon, the semicolon will auto-adjust the line of code to “testExp = 1;” This is unique in Visual Studio. Amann et al. in their study says that, “The code completion is by far the most frequently used tool in Visual Studio (87%, 78.8).” (Amann et al. 2016) It is a very powerful tool. In the website of University of South Florida, it says that, “Type variables quickly and accurately, using IntelliSense code suggestions if you get stuck Maintain speed no matter the complexity as you navigate to any file, type, member, or symbol declaration you need.” (USF) The speed of coding is a way faster and the number of errors is less with Visual Studio.
Tool 2. Errors tracking
Error tracking is why we are saving tons of time with visual studio. Both online compliers and text editors don’t provide it. In figure 4, Visual Studio has a little window which tracks these errors, the number indicates how many errors you may have. As you can see, it tells which line cause the error, sometimes it is not true due to the complexity of programming language.
Not only that, it also gives solution to your bugs. We can see in figure 4 that there is a serial number E0169. This is a link, and if you click the link, it will lead you to Microsoft website. And then it will tell you the possibilities that may cause this error, and the ways to fix it. This is an important point because for new programmers, not only they need to know where they made the mistake, but they also need to know why they made that mistake. ONLY visual studio has this functionality, all you need to do is just ONE click on the link. If you don’t do so, you then need to google your bugs, and you may not find the information you want.
Tool 3. Debug tool
A debug tool is very essential for every IDE. Every IDE will support a debugger. Since many of my classmates are still using text editors to code, I want to introduce how powerful debugger is because text editors don’t provide a debugger. And of course, Visual studio has a decent debugger, the study showed that, “The debugger is the third most frequently used tool in Visual Studio (89%, 12.8).” (Amann et al. 2016)
The most common way we debug our code is just to click “Start debugging”. Rather than running the program at once, a debugger would allow you to step through your code. For instance, if you have a loop that iterates 1000 times, the running time for our computer may just need a second. You sometimes want to know what happened in the 1000 iterations; therefore, you need a way to observe your code. In the debugging process, you are allowed to run your code one iteration at a time, meanwhile, you can see the variable changes and the behavior of your program. This is very essential, and this is why we have a special way in visual studio.
Visual studio provides another way of debugging – breakpoint. You can set a breakpoint at a point of your code, so the program will stop at that point when reached. You then can do the observation/checking you want. “Visual Studio lets you pause code execution the moment you want to inspect a big, using the breakpoint and method you need. If you’ve taken one step too far or encountered an unexpected change, you can step back to any specific line of code-no need to restart your session or recreate your state.” (USF)
No one can visualize the behavior of a huge program, so we need a useful debugger to improve our skills, especially for new programmers. Pros are pros because they know how to utilize debuggers. Text editors do not provide a debugger; Some online compliers may support debuggers, but they are not as good as the one provided in Visual Studio.
Tool 4. Separating files and color difference
Often working with C++ files can be annoying. The programming language requires the programmers to separate the files. Separating files is a good way to make your code looks clearer and more reasonable, whenever you create a new project of C++ in Visual Studio, it automatically creates some separated directories for headers, sources and main file.
This is obviously more organized and clearer that you can tell which one is a header file and which one is a main file. The online complier and text editors are fine to work with, but it will get really hard to maintain the code in the future. You may lose your files if you don’t save it periodically because of the uncertainties of online browsers.
The color difference is one of my favorite tools in Visual Studio. You can easily tell if you have any typos by these colors. Or, you can tell the type of variable by its color. In figure 3, we see that the color of word “Example” is green, so we know that the word Example is a class name because in the color of class name is green in Visual Studio.
Some modern text editors support the color identification now, and they can be as good as visual studio. However, programmers will need to work with files themselves. An online complier will allow you to work with multiple files in one window, however, their color identifications are bad. As you see in figure 2, the key word “int”, “class” and “Example” are still in white color. This wouldn’t indicate what type of variables they are. This is why we are having visual studio with all the advantages of other tools together. It is more developed and designed for not only new programmers but all programmers
The cost of downloading visual studio is worth to mention. The tool is one of the best IDEs you can have at this moment. There is no doubt that Microsoft spent a ton of money to develop this tool that supports almost every programming languages (36). This could be the reason why it is so expensive for advanced versions – starts at $45 a month. Fortunately, these two versions are not a big deal for students because they tend to serve small teams and companies. While most companies try to charge students as much as possible, Microsoft provide students a completely free tool. When you download Visual Studio Community 2019, you will see the slogan, “Free, fully-featured IDE for students, open-source and individual developers.” (Microsoft, 2019) Link for downloading is provided in work cited page.
There are some unavoidable factors when you use visual studio. First, Visual Studio can be very clunky if your computer is not good enough. This is all because of its functionalities. It provides tools more than I mentioned above, so the starting time and running time can be slow. Second, it may require a lot of disk space depends on what packages you want to install. As new programmers, this most likely won’t happen to us unless you want to install other language packages. We don’t need to worry about the operating system because it supports Windows, Max and Linux. The figure below is provided by University of South Florida about the requirement of hardware:
With this being said, as long as you have a standard computer, you can have all its good functionalities. You can find all the tools you need in visual studio whenever you need them.
Using visual studio is clearly useful and can save programmers more time. More important, as new programmers, it is a good tool for learning purpose. The tools I showed in features discussion are just part of Visual Studio. There are many that I haven’t discovered yet. How much better you feel Microsoft word is over text editor? It is how much visual studio is better than other coding tools. For students in CCNY, I strongly recommend you download and try the features I introduced above, it will make your coding skills to another level!
Amann, Sven, et al. “A Study of Visual Studio Usage in Practice”. Software Technology Group. March 2016.
Terry G, Lee, et al. “Overview of Visual Studio”. March 2019.
Amann, Sven, et al. “A Study of Visual Studio Usage in Practice”. Software Technology Group. March 2016.
University of South Florida. “Software Catalog/ Visual Studio Enterprise 2019 for Students”
Microsoft. “Visual Studio Community”