trevor kelly

trevor kelly

  • NA
  • 1
  • 3.8k

New C# programmer problem with currency output.

Oct 26 2013 6:14 AM
Hi Can someone tell me why I get ? sign instead of  the  € currency sign on my output from this code

using System;

using System.Collections.Generic;

using System.Linq;

using System.Text;

using System.Threading.Tasks;

 

namespace Currency

{

    class Program

    {

        static void Main(string[] args)

        {

          double euro,ans;

 

            Console.Write("What is 20.5 euro + 20 euro :");

            ans=Convert.ToDouble(Console.ReadLine());

 

            euro = ans;

 

            Console.WriteLine("\nThe ans is {0:C}", euro);

 

            // the output is what is 20.5 euro + 20 euro :

                   

                             //The ans is ? 40.5


Answers (2)