Skip to main content

Transfer google play balance to Paytm, PhonePe, Google Pay or any UPI linked bank account.

To transfer google play balance, opinion rewards or gift cards to PayPal, Paytm, PhonePe, Google Pay or any UPI ID linked bank account , you can use QxCredit :Rewards Convertor app which is available on google play store: You will get back 80% of the google play balance. App link:  https://play.google.com/store/apps/details?id=qxcoding.qx_credit_reboot Follow these steps to transfer your play balance to paypal or UPI: 1) download app from play store. 2) login with your google account and phone number. 3) choose a token amount which you want to convert/transfer. 4) Enter your payout details.(UPI ID or PayPal Email) 5) wait for an acknowledgement mail form qxcredit containing information about your purchased token. 6) you will receive the amount within 3 days. 7) if you face any issues you can raise a query on website: https://qx-credit.web.app/#/contact_support About app: Introducing QxCredit : Rewards Converter Convert /Transfer or Exchange your Google Play Balance and opinion r

Python and C++ program to implement multiplication of 2d array (Matrix multiplication)

Here, in this program we are going to implement matrix multiplication ,
suppose matrix 1 has dimensions:m*n
and matrix 2 has dimensions :p*q
for these two matrix to be multiplied we need to have the number of columns in matrix 1(n) equal to the number of rows in matrix 2(p),
if the condition is satisfied then the result of multiplication will be a matrix of order m*q



in multiplication the elements of the resultant matrix will be the sum of product of corresponding elements of row(of M1) and column(of M2)
//first element in 1st row in given example:
res[0][0]+=mat1[0][i] * mat2[i][0] where 0<i<n or p
//second element in 1st row:
res[0][1]+=mat1[0][i] * mat2[i][1] where 0<i<n or p
and so on…………

Example :
Input :
1 2 3   1
4 5 6   2
7 8 9   3 
Output :
14
32
50


Input :
4 3 4   2
4 1 1   1
Output :
multiplication not possible
n!=p


Here goes the main execution part where the calculation is been done:

for(int i=0;i<r1;i++)
   for(int j=0;j<c2;j++)
      for(int l=0;l<r2;l++)
           *(res+i*c2+j)+=*(arr1+i*c1+l) * *(arr2+l*c2+j);

the last statement can also be written as:
res[i][j] + = arr1[i][l] + arr2[l][j];

we are using dynamic memory allocation in this program, using calloc() , in the above code each element of res[] array is calculated by continuously adding the product of columns of arr1  (increasing ) and rows of arr2 ( increasing ).
The source code is given below in Python and C++ :

Python Source Code:


# 2D array multiplication
if __name__ == '__main__':
    r1, c1, r2, c2 = map(int, input("rows and column for matrix 1 and 2:").rstrip().split())
    if c1 != r2:
        print("Multiplication not possible:")
        exit(0)

    print("Enter elements:")
    arr1 = []
    arr2 = []
    for i in range(r1):
        arr1.append(list(map(int, input().rstrip().split())))
    for i in range(r2):
        arr2.append(list(map(int, input().strip().split())))
    res = [[0 for c in range(c2)] for r in range(r1)]
    for i in range(r1):
        for j in range(c2):
            for l in range(r2):
                res[i][j] = res[i][j] + arr1[i][l] * arr2[l][j]
    print(*res, sep='\n')


C++ Source Code:

#include <iostream>
#include<conio.h>
using namespace std;

int main(int argc, char *argv[]) {
 int r1,c1,r2,c2;
 printf("Enter row and column of matrix 1 and 2\n");
 cin>>r1>>c1>>r2>>c2;
 int *arr1=(int*)calloc(r1*c1,sizeof(int));
 int *arr2=(int*)calloc(r2*c2,sizeof(int));
 int *res=(int*)calloc(r1*c2,sizeof(int));
 
 for(int i=0;i<r1;i++)
  for(int j=0;j<c1;j++)
   cin>>*(arr1+c1*i+j);
 for(int i=0;i<r2;i++)
  for(int j=0;j<c2;j++)
   cin>>*(arr2+c2*i+j);
 for(int i=0;i<r1;i++)
  for(int j=0;j<c2;j++)
   for(int l=0;l<r2;l++)
    *(res+i*c2+j)+=*(arr1+i*c1+l) * *(arr2+l*c2+j);
 for(int i=0;i<r1;i++)
 {
  for(int j=0;j<c2;j++)
   cout<<*(res+i*c2+j);
  cout<<endl;
 }
 getch();
 return 0;
}


For downloading executable Code:  click here


if any doubts or queries please comment ðŸ™‚

Comments

Post a Comment

Popular posts from this blog

Transfer google play balance to Paytm, PhonePe, Google Pay or any UPI linked bank account.

To transfer google play balance, opinion rewards or gift cards to PayPal, Paytm, PhonePe, Google Pay or any UPI ID linked bank account , you can use QxCredit :Rewards Convertor app which is available on google play store: You will get back 80% of the google play balance. App link:  https://play.google.com/store/apps/details?id=qxcoding.qx_credit_reboot Follow these steps to transfer your play balance to paypal or UPI: 1) download app from play store. 2) login with your google account and phone number. 3) choose a token amount which you want to convert/transfer. 4) Enter your payout details.(UPI ID or PayPal Email) 5) wait for an acknowledgement mail form qxcredit containing information about your purchased token. 6) you will receive the amount within 3 days. 7) if you face any issues you can raise a query on website: https://qx-credit.web.app/#/contact_support About app: Introducing QxCredit : Rewards Converter Convert /Transfer or Exchange your Google Play Balance and opinion r

What is AI (Artificial Intelligence )? and its characteristics

Definition : Artificial intelligence  (AI) is the ability of a  computer program  or a  machine  to think and learn. It is also a field of study which tries to make computers "smart". They work on their own without being encoded with commands. Types of AI : REACTIVE MACHINES:  The most basic type of AI is purely reactive ,it does not store any memory of past or predict ( calculate ) future happenings. This type of AI is only applicable to specific applications and the principle is choosing the best decision among several options. examples: Deep Blue, IBM’s chess-playing supercomputer LIMITED MEMORY :  this type 2 kind of AI machines are distinct from reactive machine in such a way that it can make optimum decisions based on the past information ( data ). examples: self driving cars. THEORY OF MIND:  The understanding that people,creatures and objects can have thoughts or emotions which effect their own behavior. This point is the important divide

How to convert google play balance to paypal or UPI [2024]

If your google account contains play balance which you might have earned from google competitions, opinion rewards or gift vouchers, you can transfer the amount to paypal account or any UPI linked bank account.  For transferring the play balance you need to follow 3 simple steps :  1) Download QxCredit app from google play store:                                 2) Purchase a token of your choice by entering the payout details :            3) View your purchase in my tokens section and wait for 72 hours for the transaction to be verified and processed. The below video demonstrates the process of purchasing a token of your choice to convert play balance: After purchasing token you will also receive a confirmation mail from QxCredit regarding the purchased token information. You can also view your purchased token on QxCredit website:  https://qx-credit.web.app/ You can refer to the terms and condition and privacy policy of the QxCredit app on the same web