Question: Write a program in C that obtains the name of a locale from the command line and then displays the values stored in the corresponding

Write a program in C that obtains the name of a locale from the command line and then displays the values stored in the corresponding lconv structure. For example, if the locale is "fi_FI"(Finland, the output of the program might look like this:
decimal_point =","
thousands sep =""
grouping =3
mon_decimal_point =","
mon_thousands_sep =""
mon_grouping =3
positive_sign =""
negative_sign ="-"
currency_symbol = "EUR"
frac_digits =2
p_cs_precedes =0
n_cs_precedes =0
p_sep_by_space =2
n_sep_by_space =2
p_sign_posn =1
n_sign_posn =1
int_curr_symbol = "EUR "
int_frac_digits =2
int_p_cs_precedes =0
int n_cs_precedes =0
int p_sep_by_space =2
int n_sep_by_space =2
int p_sign_posn =1
int n_sign_posn =1
For readability, the characters in grouping and mon_grouping should be displayed as decimal numbers.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!