C Ejercicio Ejemplo 95
Título: ejemplos de aplicación estructura simple.
Análisis del programa: Ninguno.
Código fuente:
// Created by www.w3big.com on 15/11/9. // Copyright © 2015年 本教程. All rights reserved. // #include <stdio.h> struct programming { float constant; char *pointer; }; int main() { struct programming variable; char string[] = "本教程:http://www.w3big.com"; variable.constant = 1.23; variable.pointer = string; printf("%f\n", variable.constant); printf("%s\n", variable.pointer); return 0; }
Ejecutar la salida anterior ejemplo es:
1.230000 本教程:http://www.w3big.com