Code:
#include <stdio.h>
#include <stdlib.h>
#include "SDL/SDL.h"






// 16 x 16 pixels for stuff on the screen
#define px 16
#define maxrow    30
#define maxcol    40
#define snake_start_row    15
#define snake_start_col    20






SDL_Surface *screen = NULL;




void make_move();


void setup_board();


void randomize();




//Global
int score, snake_length, speed, level,r,c;
int obstacles=10;
char grid[maxrow][maxcol];
int direction = SDLK_RIGHT;
struct snake_segment {
    int row,col;
} snake[100];


// Start up SDL
void init() {
    // Start SDL
    SDL_Init(SDL_INIT_EVERYTHING);
    // Set the caption
    SDL_WM_SetCaption("Snake", NULL);
    //Set up Screen
    screen = SDL_SetVideoMode(640,480,32, SDL_SWSURFACE);
}


void draw() {
    // Declare Images
    SDL_Surface *food= SDL_LoadBMP("food.bmp");
    SDL_Surface *obstacle= SDL_LoadBMP("obstacle.bmp");
    SDL_Surface *background= SDL_LoadBMP("background.bmp");
    SDL_Surface *segment= SDL_LoadBMP("segment.bmp");
    SDL_Surface *blank= SDL_LoadBMP("blank.bmp");
    SDL_BlitSurface(background, NULL, screen, NULL);
    


    
    int row,col,i,j;
    


// Plot Obstacle and Food
    SDL_Rect location;
    
    for(row=0;row < maxrow;row++){
        for(col=0;col < maxcol;col++){
            location.y = row * px;
            location.x = col * px;
            if(grid[row][col] == 'o') {
                SDL_BlitSurface(obstacle, NULL, screen,&location);
            }
            else if (grid[row][col] == 'f') {
                SDL_BlitSurface(food, NULL, screen, &location);
            }
        }
    }


    for(i=0;i<snake_length;i++){
            location.y=snake[i].row * px;
            location.x=snake[i].col * px;
            SDL_BlitSurface(segment,NULL,screen,&location);
            
    }    
}


void init_board() {
    int row, col, i,j;
    snake_length=5;
    //Set up Grid
    for(row=0; row<=maxrow;row++){
        for(col=0;col<=maxcol;col++){
            grid[row][col]= ' ';
        }
    }
    // Set up obstacles
    for(i=0;i<=obstacles*2;i++){
        row= rand()%maxrow;
        col= rand()%maxcol;
        if(i<obstacles){
            grid[row][col] = 'o';
        } else {
            grid[row][col] = 'f';        
        }
    }
    
    for(j=0;j<snake_length;j++){
        snake[j].row=snake_start_row;
        snake[j].col=(snake_start_col + j);
    }        
}


int main(int argc, char **argv)
{
    SDL_Event keyevent;
    init(); // Start SDL
    // initialize the grid
    init_board();
    do { // repeatedly 
        // draw the state of the game
        draw();
        
        // await user input
        make_move();
        
        
        SDL_Flip(screen);
        
        
    } while(1);
    


}


void make_move(){
    SDL_Surface *blank= SDL_LoadBMP("blank.bmp");
    SDL_Surface *segment= SDL_LoadBMP("segment.bmp");
    SDL_Rect location;
    SDL_Event keyevent;
    int j;


    if(SDL_PollEvent(&keyevent)){
        if(keyevent.type==SDL_KEYDOWN){// (keyevent.type){
            switch(keyevent.key.keysym.sym){
                case SDLK_LEFT:
                    snake[snake_length].row=snake[snake_length-1].row; // End segment loses segments go up one row
                    snake[snake_length].col=snake[snake_length-1].col-1;
                    
                    
                    break;
                case SDLK_RIGHT:
                    snake[snake_length].row=snake[snake_length-1].row; // End segment loses segments go up one row
                    snake[snake_length].col=snake[snake_length-1].col+1;
    
                    
                    break;    
                case SDLK_UP:
                    snake[snake_length].row=snake[snake_length-1].row-1; // End segment loses segments go up one row
                    snake[snake_length].col=snake[snake_length-1].col;
                    break;
                case SDLK_DOWN:
                    snake[snake_length].row=snake[snake_length-1].row+1; 
                    snake[snake_length].col=snake[snake_length-1].col;
                    break;
                case SDLK_x:
                    exit(0);
            }
        
            
        } else if (keyevent.type == SDL_QUIT) {
            exit(0);
        }
        
    }


        
        SDL_Flip(screen);
}
When i compile this code I get my snake situated in the middle of the screen, but it will not move around. I have thought about trying to take the last segment and move it to the [snake_length] to make it move but am stuck.

Please help if possible,

Thank you