Advertisement
rrcfs

lista

May 30th, 2016
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.61 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3. #define TM 15
  4. typedef struct
  5. {
  6.     tpPont celula = novaCaixa;
  7. }Matriz;
  8.  
  9. //matriz tabuleiro[TM][TM]
  10. //quando for inserir
  11. struct tpPont
  12. {
  13.     char letra;
  14.     tpPont *ant, *prox;
  15.     tpPont *emcima, *embaixo;
  16. };
  17. struct tpDescritor
  18. {
  19.     tpPont *inicio, *fim;
  20.     int qtd;
  21. };
  22. tpPont *novaCaixa(void)
  23. {
  24.     char elemento;
  25.     tpPont *caixa = new tpPont;
  26.     caixa -> letra = elm;
  27.     caixa -> prox = NULL;
  28.     caixa -> ant = NULL;
  29.     caixa -> emcima = NULL;
  30.     caixa -> embaixo = NULL;
  31.     return caixa;
  32. }
  33. void inicializa(tpDescritor &desc)
  34. {
  35.     desc.qtd=0;
  36.     desc.inicio=NULL;
  37.     desc.fim=NULL;
  38. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement