In the above program, two strings are compared. Here,
The toUpperCase() method converts all the string characters to uppercase.
=== is used to check if both the strings are the same.
The if...else statement is used to display the result as per the condition.
Note: You can also use the toLowerCase() method to convert all the strings to lowercase and perform the comparison.
Thankyou ❣️ Subscribers
@Becoming_developer
On this page of the site you can watch the video online Class 31 || Compare Two String || Javascript Example with a duration of hours minute second in good quality, which was uploaded by the user Becoming Developer Marko G 29 December 2022, share the link with friends and acquaintances, this video has already been watched 250 times on youtube and it was liked by 5 viewers. Enjoy your viewing!