Last active
May 27, 2026 17:23
-
-
Save smah-beep/1e5defb1279301cf8e8a26c66fce5691 to your computer and use it in GitHub Desktop.
ДЗ: Освоение циклов
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Text; | |
| using System.Threading.Tasks; | |
| namespace _DZ_ | |
| { | |
| internal class Program | |
| { | |
| static void Main(string[] args) | |
| { | |
| Console.WriteLine("Добро пожаловать! Эта программа выведет написанный вами текст столько раз, сколько вы захотите!"); | |
| Console.WriteLine("Напишите текст, который вы бы хотели повторить: "); | |
| string userText = Console.ReadLine(); | |
| Console.Write("Укажите, сколько раз вы хотите повторить текст: "); | |
| int countRepeat = Convert.ToInt32(Console.ReadLine()); | |
| for (int i = 0; countRepeat > i; i++) | |
| { | |
| Console.WriteLine(userText); | |
| } | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment