Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
main.cpp
00001 #include "mbed.h" 00002 00003 Serial pc(SERIAL_TX, SERIAL_RX); 00004 00005 char nameStr[30]; // array of chars (string) 00006 int age; // integer to hold your age 00007 00008 void getData() 00009 { 00010 pc.scanf("%s %d", &nameStr, &age); 00011 } 00012 00013 int main() 00014 { 00015 getData(); 00016 00017 pc.printf("Hello %s \n\r", nameStr); 00018 pc.printf("You are %d \n", age); 00019 }
Generated on Fri Aug 19 2022 03:06:23 by
1.7.2