Problem not getting boolean value in if else function

I am testing a web page that requires 2 numbers to be entered to find the value of x in the form ax + b = 0.
I am wanting to load data from excel. Data is as follows:
image
Scrip test case:

WebUI.openBrowser('')

WebUI.navigateToUrl('http://localhost:8080/SWT_PresentTest/index.html')

WebUI.setText(findTestObject('Object Repository/Page_TODO supply a title/input_Factor a_a'), factor_a)

WebUI.setText(findTestObject('Object Repository/Page_TODO supply a title/input_Factor a_b'), factor_b)

WebUI.click(findTestObject('Object Repository/Page_TODO supply a title/input_Result_giaiBtn'))

if (WebUI.setText(findTestObject('Object Repository/Page_TODO supply a title/input_Factor a_a'), factor_a) == 0) {
	WebUI.verifyElementText(findTestObject('Object Repository/Page_TODO supply a title/span_' + result), result)
	WebUI.closeBrowser()
} else {
	WebUI.verifyElementText(findTestObject('Object Repository/Page_TODO supply a title/span_x  '+result), 'x = '+ result)
	WebUI.closeBrowser()
}

With the above test case I get the result:
image
image
image

I don’t understand the problem with my if function why not get boolean value.

Please don’t post the same question more than once.