Sponsored Content
Full Discussion: Prime Number Program (Fun)
Top Forums Shell Programming and Scripting Prime Number Program (Fun) Post 302198395 by Kweekwom on Thursday 22nd of May 2008 09:39:06 PM
Old 05-22-2008
Thanks! I didn't realize people were finding these numbers on personal computers, I guess I may make the leader board considering each core has 4 GB of memory Smilie
 

7 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Script producing error, Program to calculate maximum number

Hi folks, Here i have written a shell script to calculate a maximum number from 10 numbers entered on command line. max=0 echo Enter 10 numbers , one at a time for i in 1 2 3 4 5 6 7 8 9 10 do read n max=`expr $max + $n` if --- At this last step there is some problem, it gives error... (5 Replies)
Discussion started by: rits
5 Replies

2. UNIX for Dummies Questions & Answers

A perfect number shell program

Here's my work of testing whether a number input is perfect or not.. echo Enter a number read no i=1 ans=0 while do if then ans='expr $ans + $i' fi i='expr $i + 1' done if then echo $no is perfect else echo $no is NOT perfect fi (12 Replies)
Discussion started by: Cyansnow
12 Replies

3. Shell Programming and Scripting

Perl Prime number help

Hello, I have some extra time at work and I'm trying to come up with a good prime number generator for very large numbers that can take advantage of multiple (hundreds) cores. I realize Perl may not be the best solution for this, any ideas? Thanks! (1 Reply)
Discussion started by: Kweekwom
1 Replies

4. Solaris

Resolving port number to program name

I was just checking to see if anyone had a script that would allow me to go from port number to program name. I tried to create my own script but it looks like it only works for IPv4 sockets and it looks like daemons such as sshd return as AF_INET6 (in pfiles) for some reason. I can fix my script... (0 Replies)
Discussion started by: thmnetwork
0 Replies

5. Programming

Program wont print prime numbers

The problem I'm having is that when you put in the two numbers the answer is just prime.... nothing. I cannot figure this out ive been working on this forever, can someone please god just tell me how to fix this without encrypted "hints". #include <iostream> #include <cmath> using... (3 Replies)
Discussion started by: c++newb
3 Replies

6. Shell Programming and Scripting

Help with ahem Prime number Generating Script

Can anybody tell me why the second part of this script (Sieve of Eratosthenes) isn't working properly. This isnt coursework or homework just private studies ( Yes Project Euler began it ) I know there are easier ways of doing this too but I want to do it this way.:p Iam using Cygwin on Vista... (3 Replies)
Discussion started by: drewann
3 Replies

7. UNIX for Beginners Questions & Answers

How do I use grep to grab prime number output from my factor program?

I have a factor program that runs and outputs to stdout all the prime numbers that are specified in the given paramters, in this case 30000000-31000000. Command: factor/factor 30000000-31000000 Sample output: 30999979 = 30999979 30999980 = 2^2 5 11 140909 30999981 = 3 10333327... (6 Replies)
Discussion started by: steezuschrist96
6 Replies
HOOLA(6)							     board_gen								  HOOLA(6)

NAME
make-gnome-freecell-board, make-aisleriot-freecell-board, make-microsoft-freecell-board, make-pysol-freecell-board - Programs to generate boards to be used as input to Freecell Solver. SYNOPSIS
program [-t] board-number or for make-pysol-freecell-board: program [-t] [-F] board-number [game-string] or for make-aisleriot-freecell-board: program [-t] board-number [game-string] DESCRIPTION
These programs are command-line programs that can generate the initial board of the Freecell games of several popular Solitaire implementations. Those boards can be in turn be inputted to fc-solve by means of a pipeline, or placed inside a file for safe-keeping. make-pysol-freecell-board and make-aisleriot-freecell-board also accept an optional third argument which indicates the game type. This type defaults to Freecell, but is useful for generating the boards of other games. Note that using this flag does not preclude one from using the "--game" flag of fc-solve. make_pysol_freecell_board.py accepts another parameter called -F or --pysolfc that deals the PySolFC boards instead of the classic PySol ones. A common paradigm for using those programs is something like: bash:~$ make-microsoft-freecell-board 11982 | fc-solve -l gi If the "-t" option is specified, then the 10 cards are printed with "T"'s, instead of "10"'s. While this does not have any effect on fc- solve it may prove useful for other solvers or solitaire implementations which do not accept "10"'s. Here is a short description of each program: make-gnome-freecell-board Generate the boards of the standalone Freecell program that comes with the GNOME desktop. make-aisleriot-freecell-board Generate the Freecell boards of GNOME's AisleRiot. make-pysol-freecell-board A Python script that generates the boards of the various games of PySol. make-microsoft-freecell-board A program that generates the boards of Microsoft Freecell and of the Freecell Pro implementation of Freecell. OPTIONS
board-number is the board number as a decimal number. game-string is a string describing the game. Valid strings and their respective games are: bakers_game - Baker's Game (*) bakers_dozen - Baker's Dozen (Broken) (*) beleaguered_castle - Beleaguered Castle (*) citadel - Citadel cruel - Cruel der_katz - Der Katzenschwantz die_schlange - Die Schlange eight_off - Eight Off (*) fan - Fan forecell - Forecell freecell - Freecell (the default) good_measure - Good Measure ko_bakers_game - Kings' Only Baker's Game relaxed_freecell - Relaxed Freecell relaxed_seahaven - Relaxed Seahaven Towers seahaven - Seahaven Towers (*) simple_simon - Simple Simon (*) streets_and_alleys - Streets and Alleys make-aisleriot-freecell-board supports only the games marked with an asterisk (*). SEE ALSO
fc-solve (6) /usr/share/doc/freecell-solver-bin/README.board_gen AUTHOR
Shlomi Fish, <http://www.shlomifish.org/> . board_gen 3.12.0 2012-06-22 HOOLA(6)
All times are GMT -4. The time now is 01:43 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy