我正在尝试为数组中的值打印“x”,例如整数 32 将打印 32 个 x,但我不确定如何去做。
环顾四周,任何有关该做什么的帮助或指示都会很棒,但似乎无法找到任何可以帮助我而不会使它复杂化的东西。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace Histogram
{
class Program
{
static void Main(string[] args)
{
string output = "";
int[] x;
x = new int[18];
int[] y = { 32, 27, 64, 18, 95, 14, 90, 70, 60, 37, 17, 56, 99, 34, 75, 36, 12, 8, 100, 77 };
const int ARRAY_SIZE = 18;
int[] z;
z = new int[ARRAY_SIZE];
for (int i = …Run Code Online (Sandbox Code Playgroud)