/**: MallocLimit.c
 * by lonelyforest
 *这个程序在DOS下运行,将会输出您的内存到底能够
 *分配多大!!!
 */
#include <stdio.h>
#include <stdlib.h>

int main()
{
 int MB = 0;
 while ( malloc(1<<20) ) ++MB;
 printf("/n has %d MB memory!/n", MB);
 return 0;
}

相关文章:

  • 2021-06-26
  • 2022-12-23
  • 2021-11-23
  • 2022-03-09
  • 2022-12-23
  • 2022-01-19
  • 2022-12-23
  • 2021-11-29
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-04-23
  • 2021-10-14
  • 2021-08-23
  • 2022-01-30
相关资源
相似解决方案