<pre name="code" class="csharp">using UnityEngine;
using System.Collections;
public class example : MonoBehaviour {
public float shuzi;
public GameObject A;
public GameObject B;
void Start () {
A = GameObject.Find("A");
B = GameObject.Find("B");
}
void Update () {
A.GetComponent().text=shuzi.ToString("F2").ToString();
B.GetComponent ().text = Mathf.Round (shuzi).ToString();
}
}
