Questions: 1 835

Answers by our Experts: 1 539

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

Create a component that receives two numbers from the user through a Web Form, and

based on the user’s selection it adds or subtracts the two numbers and returns the result to

the Web Form. The result should be displayed in the Web Form.


1. Write a C# Sharp program to print Hello and your name in a separate line.


2. Given a temperature in Celsius degrees, write a method that converts it to Fahrenheit degrees.


3. Given two integers, write a method that swaps them using temporary variable.


4. Given an integer, write a method that checks if it is even.


5. Given a number, write a method that checks if it is positive, negative or zero.


6. Given a year as integer, write a method that checks if year is leap.


Using Serialization to persist business data


Q1) Define an array list and take inputs from the user and fill the array list so this array list values I want to serialize it into xml file using Soap formatter so implement this functionality.


Q2) Now create a class Customer with the following attributes

class Customer

{

public int CustomerID { set; get; }

public string CustomerName { set; get; }

public string City { set; get; }

}

Now serialize this class customer and fill the inputs into it and what values u have filled using properties of this class that customer filled object u serialize into binary format using Binary formatter and then again try to read the file and deserilize the customer object stored in binary format in that file .

U can use .dat files or .txt files as well .


Q3. An institute have decided to automate their batch details operations. The application is to be developed in such a manner that a proper directory structure is to be maintained to store the files. The directory structure to be maintained is as shown below:Academy - 1. Chennai->Chennai.txt 2. Banglore->Banglore.txt 3. Mumbai->Mumbai.txt 4. Pune->Pune.txt .You need to perform operations in C# application Create a menu based application to store batch details.· The first option in the menu should allow the user to create a directory structure and the files (if not exists)in the c drive as shown in the above figure.· The second option should accept the batch details from the user. Based on the location given by the userappend the batch details in the respective files.· The third menu option allows the user to create a backup copy of the Academy folder in D Drive .The fourth option should allow the user to view the details of the all text files


Q1. Write a Code to Read and Display the contents of a text file. Accept the name of the file from the user. Handle all the exceptions that might occur during reading.



Q2. Write a Code to perform File Copy operation. You need to accept the source and destination file names. The data should be copied from source file to destination file.

Handle all the exceptions that might occur during the file copy operation.


List of employees is available in listbox. Create an application to add selected or all

records from listbox to textbox (assume multi-line property of textbox is true)


Create class bird and implement it with interface function
Code for beginners.

Return Lines 33-34 to the form:

Console.WriteLine("Employee {0} {1}, (ID: {2}) earned {3:C}",

firstName, lastName, idNum, grossPay);


Assume employees have their wages reduced by 20% to reflect the effects of taxes:


Modify the variable declarations in Line 6 to add netPay:  public static void Main()

  {

    int idNum;

    double payRate, hours, grossPay;

    string firstName, lastName;


Add a new line of code into the program to compute netPay which is grossPay multiplied by 0.8 (80%).

Math Lesson Reminder: The 0.8 multiplier is 1.0 - 0.20. If 20% of the employee's salary goes to tax, 80% of their salary (or 100% - 20%) is what they get to keep.

Modify Lines 33-34 to print out the value of netPay as well as grossPay.


Q1.]Create a class Student and inherit it in UGstudent clas , PGstudent class with various functions like name,rollno,branch,student,etc


Q4) Create a class named User with the following attributes and it needs above address entity as subelement name of type StringmobileNumber of type String

email of type Stringaddress of type AddresscreditCardNumber of type String

Include appropriate getters, setters and constructors.

Include methods to Search for user details using mobile number. If no records, print “No records found”.Search for user details using mobile number and then change the email id of the above user to new id provided. If no records exist, print “No records found”.

List the names of users in which the given string is a substring. List the users sorted in alphabetical order. If no records exist, print “No records found”.

List the names of users from a particular district. List the users sorted in alphabetical order. If no records exist, print “No records found”.

Write a main method to test the above class. Input and Output Format:

All text in bold corresponds to inp


LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS