Java script conditional [closed]


If X and Y are two buttons that we want to make it conditional in JavaScript
In such a way that we want to assume that x is correct and y is incorrect
Now if we want to command that if the user clicks the X button alert shows up saying"correct"
Otherwise when selected Y alert shows up saying "Wrong"

What codes should we write for this issue?

Source: JavaSript – Stack Overflow

November 7, 2021
Category : News
Tags: conditional-statements | if-statement | javascript

Leave a Reply

Your email address will not be published. Required fields are marked *

Sitemap | Terms | Privacy | Cookies | Advertising

Senior Software Developer

Creator of @LzoMedia I am a backend software developer based in London who likes beautiful code and has an adherence to standards & love's open-source.