i just added a for loop for generating multiple request codes to make my multiple alarms work. But still, one alarm is overriding to another. I want to know that where is my mistake. Thanks for your time in advance.
Code is
    private void setAlarm(Calendar targetCal){
AlarmManager alarmManager = (AlarmManager)getSystemService(Context.ALARM_SERVICE);
    ArrayList<PendingIntent> intentArray = new ArrayList<PendingIntent>();
        for(int i = 0; i < 10; ++i)
        {
            Intent intent = new Intent(getBaseContext(), AlarmReceiver.class);
        // Loop counter `i` is used as a `requestCode`
        PendingIntent pendingIntent = PendingIntent.getBroadcast(getBaseContext(),
                i, intent, 0);
        alarmManager.set(AlarmManager.RTC_WAKEUP, 
                        targetCal.getTimeInMillis(),    
                pendingIntent); 
        intentArray.add(pendingIntent); 
        textAlarmPrompt.setText( "\n\n***\n"
                + "Alarm is set@" + targetCal.getTimeInMillis() + "\n"
                + "***\n");
        }
}
 
    