我真的需要帮助完成我的任务,详情如下。 [英] I really need help with my assignment, details below.

查看:63
本文介绍了我真的需要帮助完成我的任务,详情如下。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

正如标题所述,我真的需要帮助完成我的任务。由于面对我正在努力完成这项任务,我愿意支付一小笔费用。我将粘贴我迄今为止所做的代码





作业指出;



创建一个表示给定课程的成绩分布的课程。在本课程中,您应该编写

方法来执行以下任务:

•打开包含一组数据的文件(将提供)

•读入数据

•设定每个年级的数量

•设定总成绩数

•设定百分比每个等级作为0到100之间的整数#

•在控制台上显示等级分布的条形图



图表应该有正确数量的酒吧,每个等级一个。每个条形可以是一个水平行的

星号,这样一行中的星号数与每个类别的等级百分比成比例。例如,让星号表示2%,因此50个星号对应于100%。标记

水平轴以10%的增量从0到100%,并用等级标识符标记每一行。

例如,如果等级输入为1A,则为4B ,6C,2D和1F,然后输出可能如下:

As the title states,I really need help with my assignment. I will be willing to pay a small fee for help, due to the face that I am really struggling with this assignment. I will paste my code that i have done so far below


The assignment states;

Create a class that represents the grade distribution for a given course. In this class you should write
methods to perform the following tasks:
• Open a file (which will be provided) that contains a set of data
• Read in the data
• Set the number of each grade
• Set the total number of grades
• Set the percentage of each grade as a whole number between 0 and 100 inclusive
• Display a bar graph of the grade distribution on the console

The graph should have the correct number of bars, one per grade. Each bar can be a horizontal row of
asterisks, such that the number of asterisks in a row is proportionate to the percentage of grades in
each category. For example, let on asterisk represent 2%, so 50 asterisks correspond to 100%. Mark
the horizontal axis at 10% increments from 0 to 100% and label each line with a grade identifier.
For example, if the grades are entered as 1A, 4B’s, 6C’s, 2D’s and 1F, then the output might look like:

0   10   20   30   40   50   60   70   80   90  100
|    |    |    |    |    |    |    |    |    |    |
***************************************************
**** A
************** B
********************* C
****** D
E
**** F 





如果您能提供帮助,请回复此主题。







Reply to this thread if this is something that you will able to help with.


using System;
using System.IO;

public class ReadFromFile
{
    public static void Main()
    {
        string file = @"C:\Users\BenjaminStock\Desktop\grades_single.txt";

            string text = File.ReadAllText(file);

                // Display the file contect to the console. Variable text is a string.
                System.Console.WriteLine("Contents of single.txt: \n\n{0}", text);


        }
}

推荐答案

这里:

http://www.freelancer.com
here:
http://www.freelancer.com


这篇关于我真的需要帮助完成我的任务,详情如下。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆