C++ Snake game using SFML libraby
Use correct capitalization of file names
Be careful with upper case and lower case in filenames. While Windows might not treat filenames case sensitively, other operating systems might. The correct #include is:
#include &lt;SFML/Graphics.hpp&gt;

Avoid operating specific functions
You use Sleep(), which is not a standard C function, but rather Windows specific. Since you are using SFML, you can use sf::sleep() instead, like so:
sf::sleep(sf::milliseconds(60));

You can then also remove #include &lt;windows.h&gt;, and then your code compiles and runs on other platforms without errors.
Add error checking
Your code ignores errors trying to open the texture files. Make sure you report an error and exit if any of the required files cannot be found.
Split off more functionality into their own functions
You already created a function update() to handle moving the snake one frame. However, it would be nice to move more functionality out of main() into their own functions, so that the game loop in main() becomes something simple like:
while (window.isOpen()) {
    handle_input();
    update();
    draw();
    sleep(milliseconds(60));
}

Avoid moving the whole body each frame
Instead of moving the position of every element of snake[], use a std::deque to hold the positions, and inside update(), just pop the tail and add a new head:
#include &lt;deque&gt;

struct position {
    int x;
    int y;
};

std::deque&lt;position&gt; snake;

void update() {
    // Calculate the new head position
    position new_head = snake.front();
    if (direction == 'u') new_head.y--;
    else if ...;

    // Handle wraparounds here
    if (new_head.x &lt; 0) new_head.x += ...;
    if (...) ...;

    // Remove the tail and add a new head
    snake.pop_back();
    snake.push_front(new_head);
}

Using std::deque, the container knows its own length, and this makes it easy to use range-for loops. For example, to draw the snake:
for (auto position: snake) {
    sn.setPosition(position.x * size, position.y * size);
    window.draw(sn);
}

Use struct position for all positions
You can also use struct position to store the coordinates of the fruit:
position fruit;

This makes the code more consistent, and if position would have added comparison operators, it would save you from manually comparing the x and y coordinates separately. Which brings me to:
Use sf::Vector2&lt;int&gt; for the positions
SFML has a handy class to store coordinates for you, so you can write:
std::deque&lt;sf::Vector2&lt;int&gt;&gt; snake;
sf::Vector2&lt;int&gt; fruit;

This type also has x and y member variables. But, it also overloads things like operator=(), so instead of comparing x and y coordinates manually, you can write:
if (snake.front() == fruit) {
    // Handle the snake eating the fruit
}

Code formatting
Your code has inconsistent formatting, sometimes there are spaces between operators and around braces, sometimes not. It doesn't really matter that much which code style you use, as long as you are consistent. Instead of manually fixing style issues, consider using a code formatting tool (either an external one like Artistic Style, or your editor's built-in code formatting functions) to keep your code looking tidy.