Aprendendo a utilizar alocação dinâmica de memória

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
Jamess
Date:
Thu Aug 06 13:56:54 2015 +0000
Commit message:
Aprendendo a utilizar aloca??o din?mica de mem?ria;

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
diff -r 000000000000 -r b2616aa3f8e4 main.cpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Thu Aug 06 13:56:54 2015 +0000
@@ -0,0 +1,11 @@
+#include "mbed.h"
+
+DigitalOut myled(LED1);
+Serial pc(USBTX,USBRX);
+
+int main() {
+    int *james = new int;
+    *james = 12;
+    
+    pc.printf("%i",*james);
+}
diff -r 000000000000 -r b2616aa3f8e4 mbed.bld
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Thu Aug 06 13:56:54 2015 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/b9ad9a133dc7
\ No newline at end of file