FULLSTACKDEVS Telegram 688
#csharp
#dotnet
#comparison

روش های بد مقایسه رشته ها در سی شارپ

تا به حال اکثرا از ToLowerیا ToUpper برای مقایسه رشته های غیر حساس به حروف بزرگ استفاده می کردیم .

اما این بهترین راه برای انجام آن نیست.

استفاده از string.Equals این مقایسه از سرعت عملکرد بهتری برخوردار است (در واقع به حروف کوچک یا بزرگ رشته ها علاقه ای نداریم).

همانطور که در تصویر می بینیم.

پس برای مقایسه دو رشته string بهتره از String.Equals استفاده کنیم

@fullStackDevs



tgoop.com/fullStackDevs/688
Create:
Last Update:

#csharp
#dotnet
#comparison

روش های بد مقایسه رشته ها در سی شارپ

تا به حال اکثرا از ToLowerیا ToUpper برای مقایسه رشته های غیر حساس به حروف بزرگ استفاده می کردیم .

اما این بهترین راه برای انجام آن نیست.

استفاده از string.Equals این مقایسه از سرعت عملکرد بهتری برخوردار است (در واقع به حروف کوچک یا بزرگ رشته ها علاقه ای نداریم).

همانطور که در تصویر می بینیم.

پس برای مقایسه دو رشته string بهتره از String.Equals استفاده کنیم

@fullStackDevs

BY Web Devs




Share with your friend now:
tgoop.com/fullStackDevs/688

View MORE
Open in Telegram


Telegram News

Date: |

In the next window, choose the type of your channel. If you want your channel to be public, you need to develop a link for it. In the screenshot below, it’s ”/catmarketing.” If your selected link is unavailable, you’ll need to suggest another option. It’s yet another bloodbath on Satoshi Street. As of press time, Bitcoin (BTC) and the broader cryptocurrency market have corrected another 10 percent amid a massive sell-off. Ethereum (EHT) is down a staggering 15 percent moving close to $1,000, down more than 42 percent on the weekly chart. The SUCK Channel on Telegram, with a message saying some content has been removed by the police. Photo: Telegram screenshot. To view your bio, click the Menu icon and select “View channel info.” As of Thursday, the SUCK Channel had 34,146 subscribers, with only one message dated August 28, 2020. It was an announcement stating that police had removed all posts on the channel because its content “contravenes the laws of Hong Kong.”
from us


Telegram Web Devs
FROM American