import java.io.*;
import java.util.*;
public class image
{
    public static void main(String args[])throws IOException
    {
        BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
        String s[]=br.readLine().split(" ");
        int n=Integer.parseInt(s[0]);
        int a=Integer.parseInt(s[1]);
        int b=Integer.parseInt(s[2]);
        int t=Integer.parseInt(s[3]);
        String str=br.readLine();
        long front[]=new long[n];
        long back[]=new long[n];int k=1,ind1=-1,ind2=-1;
        for(int i=0;i<n;i++)
        {
            if(i==0)
            {
                if(str.charAt(0)=='w')
                {
                    front[i]=b+1;
                }
                else
                {
                    front[i]=1;
                }
            }
            else
            {
                if(str.charAt(i)=='w')
                {
                    front[i]=front[i-1]+b+1+a;
                }
                else
                {
                    front[i]=front[i-1]+a+1;
                }
            }
            if(front[i]<=t)
            {
                ind1=i;
            }
        }
        back[0]=front[0];
        int c=n-1;
        while(c>0)
        {
            if(str.charAt(c)=='w')
            {
                back[k]=back[k-1]+b+1+a;
            }
            else
            {
                back[k]=back[k-1]+a+1;
            }
            if(back[k]<=t)
            {
                ind2=k;
            }
            c--;
            k++;
        }
        if(ind1==-1 && ind2==-1)
        System.out.println("0");
        else if(ind1==-1)
        System.out.println(ind2+1);
        else if(ind2==-1)
        System.out.println(ind1+1);
        else
        {
            int max=ind1+1,right=ind1,left=n-1,leftc=1;
            System.out.println(ind1+" "+ind2);
            while(right>=0)
            {
                if(right>= leftc)
                {
                    if(right<left)
                    {
                    if(back[leftc]+(leftc*a)+front[right]-front[0] <=t)
                    {
                        max=(int)(Math.max(max,right+1+leftc));
                        leftc++;
                        left--;
                    }
                    else
                    {
                        right--;
                    }
                }
                else
                break;
                }
                else
                {
                    if(right<left)
                    {
                        if(front[right]+(right*a)+back[leftc]-back[0] <=t)
                        {
                            max=(int)(Math.max(max,right+1+leftc));
                            leftc++;
                            left--;
                        }
                        else
                        right--;
                    }
                    else
                    break;
                }
            }
            System.out.println(max);
        }
    }
}