title: Do not concatenate text displayed with setText. Use resource string with placeholders
body: <p>I am a newbie in android development,
  I want to provide a number to <code>setText</code>, I am facing this problem and tried many ways to solve it.</p>
  <p>Code is:</p>
  <pre><code>public class GameActivity extends Activity implements View.OnClickListener{
      int correctAnswer;
      Button buttonObjectChoice1;
      Button buttonObjectChoice2;
      Button buttonObjectChoice3;
  
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
      //here we initialize all our varibles
      int partA = 9;
      int partB = 2;
      correctAnswer = partA * partB;
      int wrongAnswer1 = correctAnswer - 1;
      int wrongAnswer2 = correctAnswer + 1;
      TextView textObjectPartA = (TextView)findViewById(R.id.textPartA);
      TextView textObjectPartB = (TextView)findViewById(R.id.textPartB);
      buttonObjectChoice1 = (Button)findViewById(R.id.buttonChoice1);
      buttonObjectChoice2 = (Button)findViewById(R.id.buttonChoice2);
      buttonObjectChoice3 = (Button)findViewById(R.id.buttonChoice3);
      textObjectPartA.setText(&quot;&quot; + partA);
      textObjectPartB.setText(&quot;&quot; + partB);
      buttonObjectChoice1.setText(&quot;&quot; + correctAnswer);
      buttonObjectChoice2.setText(&quot;&quot; + wrongAnswer1);
      buttonObjectChoice3.setText(&quot;&quot; + wrongAnswer2);
      buttonObjectChoice1.setOnClickListener(this);
      buttonObjectChoice2.setOnClickListener(this);
      buttonObjectChoice3.setOnClickListener(this);
  </code></pre>
  <p>errors in last 8th line to last 4th line.</p>
  <p><a href="https://i.stack.imgur.com/nVdSz.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/nVdSz.png" alt="Error image" /></a></p>