Updating an interger in a GUIText

Hey so im having a little problem with this code.

var gText1: GUIText;
var gText2: GUIText;
var gameHolder : GameObject;
var flashlightObj : Light;

function Update(){
 gText1.text = gameHolder.GetComponent(NewerGameScript).totalNotebooks;
 
 gText2.text = flashlightObj.GetComponent(FlashlightBattery).batteryLife;
}

When i use this script it gives me an error that says “Cannot convert ‘int’ to ‘String’.” so how can i show an interger on a string?

cast it to string

gText1.text = gameHolder.GetComponent(NewerGameScript).totalNotebooks.ToString();
gText2.text = flashlightObj.GetComponent(FlashlightBattery).batteryLife.ToString();