>>406 力尽きた。最後の表示が半角のまま。
#include <stdio.h>
double input()
{
    unsigned char s[2];
    int c;
    double v = 0.0, div;
    while (scanf("%*[\x82]%1[\x4f-\x58]", s) == 1)
        v *= 10, v += s[0] - 0x4f;
    if (scanf("%*[\x81]%1[\x43-\x44]", s) == 0)
        return v;
    for (div = 10.0; scanf("%*[\x82]%1[\x4f-\x58]", s) == 1; div *= 10)
        v += s[0] / div;
    return v;
}
double mean(double a, double b, double c) { return (a + b + c) / 3; }
int main(void)
{
    int i, c;
    double v[3], m;
    for (i = 0; i < 3; ++i) {
        printf("実数%.2s;", &("123"[2 * i]));
        v[i] = input();
        while ((c = getchar()) != EOF && c != '\n') {}
    }
    m = mean(v[0], v[1], v[2]);
    printf("平均値=%f\n", m);
    return 0;
}