How can I find the name of an object with a number in it?

This might sound really confusing so I will try my best to explain. Feel free to ask me if you need it clarified.

I have 6 imagelabels with a textlabel inside each one called “name” in my GUI. Here they are:

I have a script where I want to change the text of the “name” textlabel in each imagelabel. I want to access them all but I want to do it by using their names with the number value. For some reason I remember being able to do this with a bracket like I tried to do below but it’s erroring back saying I am trying to access “r” and not “r1” when the number value is 1 for example.

player.PlayerGui.ScreenGui.Frame.r[number].name.Text = theText

I just want to know if there is a way to access each imagelabel by using r followed by the number value. The number value would only be 1-6 so it would be the same number values of the names of the imagelabels.

Ideally I want to do it without any for loops because I have other things in the GUI than those 6 imagelabels and I want to keep it simple. I just want to know if a format exists where I can access each one by “r” with the number following it.

In case this is still confusing, how can I get “r1” when the “number” value is 1. I thought I could do this by doing r[number] when number is equal to 1 but maybe I am not formatting it right.

You can do

player.PlayerGui.ScreenGui.Frame:FindFirstChild("r"+tostring(number)).name.Text = theText

Thanks it totally worked! I just had to change the + to 2 dots to format the string correctly.

player.PlayerGui.ScreenGui.Frame:FindFirstChild("r"..tostring(number)).name.Text = theText

Yeah, they must have conflated Python syntax with Lua syntax, in Lua the concatenator operator is denoted by two consecutive periods.

Yeah in Unity C# it makes more sense, it is done with a plus operator