Get the App
SLTechnology News&Howtos  ›  Development  › 

How to realize the batch processing of changing lowercase string to uppercase and delaying output

Shulou Source: shulou.com Published: 2022-06-03 08:16:17 10月16日 Update

This article mainly introduces how to realize the batch processing of lowercase string to uppercase and delay output. it has a certain reference value, and interested friends can refer to it. I hope you will gain a lot after reading this article. let the editor take you to understand it.

Having a problem

1 master the skills of uppercase and lowercase interchange

2 master the skills of delay output

3. Master the skills of character interception.

Problem-solving requirements

1 ensure that the code is efficient and universal

2. Keep the code as concise as possible.

3 do not generate temporary files

Bonus rule

1 unique benchmark score of 5 points

2 code efficiency, general benchmark score 4 points

3 skill superb benchmark score 3 points

4 code simplicity benchmark score 2 points

5 perfect code plus 15 points

The topics are as follows

There is a string i like the bathome,because here is the batch of the world.

Batch processing is required to capitalize all letters of the string and delay the output on the screen with the effect of typing.

Batman:

The code is as follows:

@ echo off set "str=i like the bathome,because here is the batch of the world." Set "code=A B C D E F G H I J K L N M O P Q R S T U V W X Y Z" for%% I in (% code%) do call,set "str=%%str:%%i=%%i%%": lp set / packs% struju if defined str goto lp pause 1% nul if defined str goto lp pause > nul

Terse:

The code is as follows:

@ echo off&setlocal EnableDelayedExpansion set "str=i like the bathome,because here is the batch of the world." For% I in (A B C D E F G H I J K L M N O P Q R S T U V W X Y Z) do set stranded stranded if not%% iSuppli% I!: lp set and paired stranded if not% n% Magi 1 thanks to you for reading this article carefully. I hope the article "how to change the string from lowercase to uppercase and delay the output of batch processing" shared by the editor is helpful to everyone. At the same time, I also hope that you can support us and pay attention to the industry information channel. More related knowledge is waiting for you to learn!

Tags: Code characters strings output benchmarks skills articles uppercase lowercase simplicity plus points unique superb lower value interest at the same time letters screens ideas Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MySQL Xiaomi Shulou Tech Info Linux macOS