[Question]
  [
## The challenge
Write a program or function that prints stars! The program will receive two parameters by standar input: Size of the star and number of points of the star. A star can be any size between 0 and 10 and have 3, 4 or 5 points. The input parameters are separated by a comma, for example: `5,3` means a size 5 star with 3 points. The stars are composed by asterisks `*`
Consider the program will only receive valid inputs.
The prints must be correctly spaced so we can see pretty stars in the output!
## Parameters explanations
## Points
Is the number of arms counting from the central asterisk.
**3 points stars**:
```
       *
       *
       *
     *   *
    *     *
```
They are composed by a vertical arms and two diagonal arms. The separation between diagonal arms is `2*size-1`
**4 points stars**
```
   *     *
    *   *
      *
    *   *
   *     *
```
They have the form of a X and composed by two diagonal lines. The separation between lines is `2*(size-1)+1`
**5 points stars**
```
     *
     *
 * * * * *
    * *
   *   *
```
They are composed by a vertical line and a horizontal line. Each asterisk in the horizontal line is separated by one space. Also they have two diagonal lines, with a separation between themselves of `2*(size-2)+1`
## Size
Size is the number of asterisks that has each arm of the star counting from the central asterisk (inclusive).
**Size 1 stars are composed by a single asterisk**
```
*
```
**Size 2 stars examples**
**3 points**
```
       *
       *
     *   *
```
**4 points stars**
```
    *   *
      *
    *   *
```
**5 points stars**
```
     *
   * * *
    * *
```
You have examples of the size 3 stars in the Points parameter explanation.
## Winning criteria
Shortest code wins. Code have to be checked with the following input parameters: `3,2` `3,3` `4,2` `4,3` `5,2` `5,3`
## Bonus
**-25% characters count** for creating a size 6 pointed with the criteria explained before (6 arms and the size is the number of asterisks counting from the central asterisk). It can be any form you want while it respect the specifications. A example of a size 6 star with size 3:
```
      *
      *
  * * * * *
    * * *
   *  *  *
```
6 points stars must be checked with the following inputs `6,2` `6,3`.
  
[Answer]
# Mathematica 80 76 67 chars
Some would question whether this is ASCII art, but I couldn't resist.
```
Graphics@Table[Text["*", r {Cos@t, Sin@t}], {t,0,2π,2π/#1}, {r,0,#2-1}]&
```
**Usage** (setting the font size at 24 to make the stars appear large.)
```
Graphics@Table[Text["*"~Style~24, r {Cos@t, Sin@t}], {t,0,2π,2π/#1}, {r,0,#2-1}] &[6,4]
```
![six four](https://i.stack.imgur.com/Pt5HY.png)
---
**Output** for the following cases:
{{3, 2}, {3, 3}, {4, 2}, {4, 3},
{5, 2}, {5, 3}, {6, 2}, {6, 3},
{7, 4}, {8, 3}, {9, 2}, {12, 4}}
![framed stars](https://i.stack.imgur.com/cQgyc.png)
---
**How it works**
(a) The first star is at the origin of a coordinate space. Let's display it.
(b) Afterwards, we'll display a point at {1,0}.
(c) Then 5 points at once. We applied a pure function onto each pair of coordinates that follows it.
(d) Use Cos and Sin to determine the coordinates
(e) Coordinates work only on unit circle; 6 is the number of light beams.
(f) Draw radii from 0 to 4 unit.
```
options = Sequence[Axes -> True, ImageSize -> 225, BaseStyle -> 14];
a = Graphics[Text["*"~Style~{28, Blue}, {0, 0}], PlotLabel -> Style["a", 20], options];
b = Graphics[Text["*"~Style~{28, Blue}, {1, 0}], PlotLabel -> Style["b", 20], options];
c = Graphics[Text["*"~Style~{28, Blue}, {#1, #2}] & @@@ {{0, 0}, {1, 0}, {0, 1}, {-1, 0}, {0, -1}}, PlotLabel -> Style["c", 20], options];
d = Graphics[Text["*"~Style~{28, Blue}, {Cos@#, Sin@#}] & /@ {0, \[Pi]/3, 2 \[Pi]/3, \[Pi], 4 \[Pi]/3, 5 \[Pi]/3}, PlotLabel -> Style["d", 20], options];
e = Graphics@Table[Text["*"~Style~24, {Cos@t, Sin@t}], {t, 0, 2 \[Pi],  2 \[Pi]/#1}] &[6];
f = Graphics@Table[Text["*"~Style~24, r {Cos@t, Sin@t}], {t, 0, 2 \[Pi], 2 \[Pi]/#1}, {r, 0, #2 - 1}] &[6, 4];
GraphicsGrid[{{a, b, c}, {d, e, f}}, Dividers -> All]
```
![explanation](https://i.stack.imgur.com/NWV86.png)
[Answer]
# Ruby, ASCII, ~~193~~ score 142 (189 chars - 25 % bonus)
```
def s r,d
f=->a,n{[n*Math.sin(a),n*Math.cos(a)]}
s=d*6
p=[]
s.times{|k|p<<" "*s}
c=s/2
p[c][c]=?*
r.times{|a|d.times{|l|x,y=f[6.28/r*a,d*l]
p[c+x.round][c+y.round]=?*}}
p.map{|j|puts j}
end
```
[Test it online](http://ideone.com/RzAUT)
I think it qualifies for the 6-rays star bonus.
```
      *     *     
                  
       *  *       
                  
                  
   *  *  *  *  *  
                  
                  
        *  *      
                  
      *     *     
                  
                  
                  
            
            
            
            
     * *    
            
    * * *   
            
     * *    
            
            
            
                        
                        
      *           *     
                        
                        
        *       *       
                        
                        
                        
          *   *         
                        
                        
*   *   *   *   *   *   *
                        
                        
          *   *         
                        
                        
                        
        *       *       
                        
                        
      *           *   
                  
```
[Answer]
## *Mathematica*, ~~65~~ 64
My take on David's method:
```
f@p_=Graphics@Array[Text["*",{Cos@#,Sin@#}&[2π/p[[1]]#]#2]&,p,0]
```
Use:
```
f @ {6,4}
```
![enter image description here](https://i.stack.imgur.com/VgNyU.png)
Errors are produced because of the use of `=` rather than `:=`, and it isn't the proper way to make a definition, but it does work here.
If one were allowed to use dots instead of asterisks this could be written (52 chars):
```
f@p_:=Most@ListPolarPlot@Array[{2π/p[[1]]#,#2}&,p,0]
f @ {6, 4}
```
![enter image description here](https://i.stack.imgur.com/r8RPz.png)
[Answer]
```
use subs qw /N W E S NW NE SE SW Circler Printer/;
($size,$points)=split(/\,/,$ARGV[0]);
my $arrsize = $size>$points ? $size : $points;
for $my (0...2*$arrsize-2) {
    $starArray[$my]=(); 
}
if($size == 3) {
    @armlist=('N','SW','SE');
}
elsif($size == 4) {
    @armlist=('NE','NW','SW','SE');
}
elsif($size == 5) {
    @armlist=('E','N','W','SW','SE');
}
elsif($size == 6) {
    @armlist=('E','N','W','SW','S','SE');
}
elsif($size == 7) {
    @armlist=('E','N','W','SW','S','SE','NE');
}
elsif($size == 8) {
    @armlist=('E','N','W','SW','S','SE','NE','NW');
}
Circler;
Printer;
sub Circler{
    for (@armlist) {
        &{$_};
    }
}
sub Printer{
    for $my1 (0...2*$arrsize-2) {
        for $my2 (0...2*$arrsize-2) {
            print "$starArray[$my1]->[$my2]"."\t"; 
        }
        print "\n\n";
    }
}
sub N {
    for $my (0...$points-1) {
        $starArray[$arrsize-1-$my]->[$arrsize-1]="*"; 
    }
}
sub E {
    for $my (0...$points-1) {
        $starArray[$arrsize-1]->[$arrsize-1+$my]="*"; 
    }
}
sub W {
    for $my (0...$points-1) {
        $starArray[$arrsize-1]->[$arrsize-1-$my]="*"; 
    }
}
sub S {
    for $my (0...$points-1) {
        $starArray[$arrsize-1+$my]->[$arrsize-1]="*"; 
    }
}
sub NW {
    for $my (0...$points-1) {
        $starArray[$arrsize-1-$my]->[$arrsize-1-$my]="*"; 
    }
}
sub NE {
    for $my (0...$points-1) {
        $starArray[$arrsize-1-$my]->[$arrsize-1+$my]="*"; 
    }
}
sub SE {
    for $my (0...$points-1) {
        $starArray[$arrsize-1+$my]->[$arrsize-1+$my]="*"; 
    }
}
sub SW {
    for $my (0...$points-1) {
        $starArray[$arrsize-1+$my]->[$arrsize-1-$my]="*"; 
    }
}
__END__;
```
]