Question: How do I write a list containing two prime numbers (100 digits each) to a text file in a specific directory?

Hi :)

I have a Macbook Air running on OS X Mavericks. I am using Maple16.

I created a procedure, which construct two keys. Each of those keys consists of a list containing two elements. That is two primes. So at the end of my procedure I included the following code in order to write my data to a file:

> pkey := fopen(keyFile, WRITE, TEXT);
                      pkey:=1
> writedata(pkey, publicKey);
> fclose(pkey);

The problem is that I can't find the created file "keyFile".

So I tried breaking the problem down. I created a List and wanted to write that list in a textfile in a specific folder:

> L := [1, 2, 3];
> fd := fopen("Users\\****\\Desktop\\fdtest.txt", WRITE, TEXT);
                              fd:=1
> fprintf(fd, "This is a test");
                              14
> fclose(fd);

But this did not work either. It seems like the file fdtest.txt never gets created. This happens in general when I use fopen().

Thank you in advance for your help

Schloemilch

 

 

Please Wait...