Difference between revisions of "User:Aelynn Akina"

From Second Life Wiki
Jump to navigation Jump to search
Line 1: Line 1:
Hello, this is my page on the Second Life wiki. Updates to come. :)
Hello, this is my page on the Second Life wiki. Updates to come. :)
[[Image:Sta_travel_hd_003.jpg|thumb|200px|Aelynn Akina at STA Travel]]


==Profile==
==Profile==

Revision as of 17:40, 9 November 2007

Hello, this is my page on the Second Life wiki. Updates to come. :)

Aelynn Akina at STA Travel


Profile

On Second Life, my profile reads:

"Hey I'm Aelynn. I'm the weaker version of Lolliipop she can push me off tables and chairs) except I'm taller and I'm not a furry or a dragon and not as crazy. I also am not from England I suppose. As in I don't live there. Nor was I ever from there. Also I don't have "loads" of English friends or anything. I wish I did sometimes.
I love my friends on SL. All of them. I think.... wait.. I'm not so sure.
I am now a spy for hire. Message for details :)"

Scripts

Herein I will describe some scripts that I wrote while bored.


// Qsort function. Pass it a list of floats and it will sort them
// in numerical order. 

list qsort(list ls) {
    //Make partition
    list LESS;
    list PIVOT;
    list GREATER;
    
    //Check if listlen is 1 or none
    if ( llGetListLength(ls) <= 1)
        return ls;

    // Get random pivot value 
    integer random_index = (integer) llFrand(llGetListLength(ls) - 1); 
    
    // Get the value at the random pivot value 
    float pivot_val = llList2Float(ls, random_index); 

    // Declare iterator and partition
    integer i;
    for ( i = 0; i < llGetListLength(ls); i++) {
        float to_be_sorted = llList2Float(ls, i);
        if ( to_be_sorted < pivot_val) {
            LESS += [to_be_sorted];
        } else if ( to_be_sorted == pivot_val) {
            PIVOT += [to_be_sorted];
        } else {
            GREATER += [to_be_sorted];
        }
    }
    // Do recursion and return
    return (  qsort(LESS) + PIVOT + qsort(GREATER) );
}