Get the App
SLTechnology News&Howtos  ›  Development  › 

How to determine whether it is a special character in batch bat

Shulou Source: shulou.com Published: 2022-06-03 08:42:58 11月15日 Update

This article is about how batch bat determines whether it is a special character or not. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.

Batch processing to determine whether it is a special character

Used to determine whether a character entered is a symbol in & ^ >.

Note that the spaces in the matching string cannot be omitted!

Batch code:

@ echo offset Input=S set / p Input=Please input a number:set Filter=S%Input%echo off > nul 2 > nul rem replace "with > set Filter=%Filter:" = >% echo% Filter%arem & if "% Filter%" = = "S" echo and rem ^ if "% Filter%" = = "Secho off 2" echo fanrem > if "% Filter%" = = "S off 2" echo gtrecho% Filter% Thank you for reading! On "batch bat how to judge whether special characters" this article is shared here, I hope the above content can be of some help to you, so that you can learn more knowledge, if you think the article is good, you can share it out for more people to see it!

Tags: Characters special content more articles good practical code strings articles look knowledge spaces symbols references help related input Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MariaDB Huawei MySQL OPPO Reno NVidia