File: OracleCreator.pl

package info (click to toggle)
dmrgpp 6.06-2
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 113,900 kB
  • sloc: cpp: 80,986; perl: 14,772; ansic: 2,923; makefile: 83; sh: 17
file content (29 lines) | stat: -rw-r--r-- 406 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/usr/bin/perl -w
use warnings;
use strict;

package OracleCreator;

sub doMain
{
	my ($doIt,$roots)=@_;
	$doIt = 0 if (!defined($doIt));

	foreach (@$roots) {
		doThisRoot($_);
	}
}

sub doThisRoot
{
	my ($root)=@_;
	for ($i=0;$i<800;$i++) {
		my $f = "$root$i.txt";
		next unless (-r "results/$f");
		system("cp results/$f oracles/$f") if ($doIt);
		print STDERR "cp results/$f oracles/$f\n";
	}
}

1;