Question

1. Create a project named DBQuiz1 2. Paste the following code to the main: string name="Smith"...

1. Create a project named DBQuiz1 2. Paste the following code to the main: string name="Smith" int num1 = 5.25; WriteLn("WELCOME TO MY PROGRAM"); WriteLine("I hope you are doing well); WriteLine("Please enter your name: "); ReadLine(); WriteLine("{0} it is nice to meet you", name); 3. Add using static System.Console to the top your project 4. Fix all the errors.

0 0
Add a comment Improve this question Transcribed image text
Answer #1
using static System.Console;

class Program
{
    static void Main() {
        string name;
        //int num1 = 5; 
        WriteLine("WELCOME TO MY PROGRAM");
        WriteLine("I hope you are doing well"); 
        WriteLine("Please enter your name: "); 
        name = ReadLine(); 
        WriteLine("{0} it is nice to meet you", name); 
    }
}
Add a comment
Know the answer?
Add Answer to:
1. Create a project named DBQuiz1 2. Paste the following code to the main: string name="Smith"...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • The following file has syntax and/or logical errors. In each case, determine the problem, and fix...

    The following file has syntax and/or logical errors. In each case, determine the problem, and fix the program. using System; using static System.Console; using System.IO; class DebugFourteen1 { static void Main() { string fileName; string directory; string path; string files; int x; Write("Enter a directory: "); directory = ReadLine(); if(Directory.Exists(Directory)) { files = Directory.GetFiles(directory); if(files.Length = 0) WriteLine("There are no files in " + directory); else { WriteLine(directory + " contains the following files"); for(x = 0; x <= files.Length;...

  • In Chapter 4 of your book, you created an interactive application named MarshallsRevenue that prompts a...

    In Chapter 4 of your book, you created an interactive application named MarshallsRevenue that prompts a user for the number of interior and exterior murals scheduled to be painted during a month and computes the expected revenue for each type of mural. The program also prompts the user for the month number and modifies the pricing based on requirements listed in Chapter 4. Now, modify the program so that the user must enter a month value from 1 through 12....

  • FIX THE FOLLOWING JAVA CODE public class Errors public static main(String[] args) { float sum int...

    FIX THE FOLLOWING JAVA CODE public class Errors public static main(String[] args) { float sum int a = 27.5, b = 72.99; suma(a, b); System.out.println("Suma = %7:3b", sum); } //end main public static suma(float a, double b) { double suma suma = a + b; } }//end class

  • signature 1. Create a new NetBeans Java project. The name of the project has to be...

    signature 1. Create a new NetBeans Java project. The name of the project has to be the first part of the name you write on the test sheet. The name of the package has to be testo You can chose a name for the Main class. (2p) 2. Create a new class named Address in the test Two package. This class has the following attributes: city: String-the name of the city zip: int - the ZIP code of the city...

  • Open BlueJ and create a new project (Project->New Project...). Create a new class named ListsDemo. Open the source code and delete all the boilerplate code. Type in the code to type (code to type...

    Open BlueJ and create a new project (Project->New Project...). Create a new class named ListsDemo. Open the source code and delete all the boilerplate code. Type in the code to type (code to type with bigger font) exactly as shown, filling in your name and the date in the places indicated. The code is provided as an image because you should type it in rather than copy-paste. If you need the code as text for accessibility, such as using a...

  • Java 1. Create an application named NumbersDemo whose main() method holds two integer variables. Assign values...

    Java 1. Create an application named NumbersDemo whose main() method holds two integer variables. Assign values to the variables. In turn, pass each value to methods named displayTwiceTheNumber(), displayNumberPlusFive(), and displayNumberSquared(). Create each method to perform the task its name implies. 2. Modify the NumbersDemo class to accept the values of the two integers from a user at the keyboard. This is the base code given: public class NumbersDemo { public static void main (String args[]) { // Write your...

  • Create a C++ project called lab3b and add the following source code init_struct.cpp to the project....

    Create a C++ project called lab3b and add the following source code init_struct.cpp to the project. #include <iostream> #include <string> #include <iomanip> using namespace std; // This program demonstrates partially initialized structure variables // PLACE YOUR NAME HERE struct taxPayer {        string name;        long socialSecNum;        float taxRate; float income; float taxes; }; int main() {        // Fill in code to initialize a structure variable named citizen1 so that        // the first three members are initialized....

  • 8. Exercise 5.6 Switch Statements Objective: Create a switch statement that accepts an integer input from...

    8. Exercise 5.6 Switch Statements Objective: Create a switch statement that accepts an integer input from 1 to 12 and returns a String of the related month name. For any other number, return Invalid Number. Steps: Create a file named Ex_5_6.java and appropriate class name and main() method. Create a method using the following signature: pubilc static String monthNumberToString(int monthNumber) In the main() method, add in the following code: System.out.println(monthNumberToString(1)); This will allow you to test your code. Modify the...

  • Create another Java class named EmployeeMain within the same project, which includes the main method. a....

    Create another Java class named EmployeeMain within the same project, which includes the main method. a. Include another class named Employee in the same Java file. This class has the following instance variables and instance methods. Define all the instance/static variables with private access modifier and constructors, instance/static methods with public access modifier. Instance Variables empID: int employeeName: String basicSalary: double Constructor Set the value for empID. Instance Methods Get and set methods for all instance variables. displayEmployee: Display the...

  • Answer in eclispe please!!! Do the following: 1. Create a package named, “prob3” and a class...

    Answer in eclispe please!!! Do the following: 1. Create a package named, “prob3” and a class named, “Games2”. 2. Create a Player class and add this code: public class Player { private String name; private int points; public Player(String name, int points) { this.name = name; this.points = points; } public String getName() { return name; } public int getPoints() { return points; } @Override public String toString() { return "name=" + name + ", points=" + points; } }...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT