K
K
Keterone2021-09-13 17:54:16
C++ / C#
Keterone, 2021-09-13 17:54:16

How to add a number to an array?

The program is made using Windows forms. I'm new to C#, I don't know how to push into an array the numbers that the user enters into the textBox.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vladimir Korotenko, 2021-09-13
@Keterone

Look at collection types.
In general, an array has a specific size.
so you probably better use the
editor ate ad

var list = new List<float>();
list.Add(float.Parse(txtBox.Text));

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question